Answer to Question #241649 in C++ for Princewill Unuigbe

Question #241649

 Write a program that uses the following three structures to store the weather data for a particular month:  



1
Expert's answer
2021-09-24T18:57:31-0400


#include <iostream>


using namespace std;


struct weather{
    double rainfall;
    double humidity;
    double temperature;
};
int main()
{
    struct weather w;
    cout<<"\nEnter rainfall: ";
    cin>>w.rainfall;
    cout<<"\nEnter humidity: ";
    cin>>w.humidity;
    cout<<"\nEnter temperature: ";
    cin>>w.temperature;


    cout<<"rainfall: "<<w.rainfall;
    cout<<"humidity: "<<w.humidity;
    cout<<"temperature: "<<w.temperature;
    return 0;
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS