+ 2

Can someone give me the code please?

Create a Temperature application that declares and initializes a temperatures array with 12 temperatures that represent the monthly high temperature. Display the name of each month and the corresponding high monthly temperature on a separate line.

1st Apr 2017, 12:29 AM
Akon
8 Answers
+ 4
Why don't you try writing it by yourself? :)
1st Apr 2017, 12:34 AM
Eligijus Silkartas
Eligijus Silkartas - avatar
+ 3
if you want the code given to you, you can Google that easily. However, i highly recommend working on it yourself so you learn how to do this, you'll need to do arrays in an organized list at some point again if you continue programming, so you will appreciate the experience then
1st Apr 2017, 12:37 AM
William La Flamme
William La Flamme - avatar
+ 3
then you should know you need loop
1st Apr 2017, 1:20 AM
Heng Jun Xi
Heng Jun Xi - avatar
+ 2
I'll try to give you some idea... what data type should use to store value for temperature? You are printing the month and the corresponding temperature, are you repeating stuff?
1st Apr 2017, 12:53 AM
Heng Jun Xi
Heng Jun Xi - avatar
+ 1
Yes 12 times
1st Apr 2017, 12:59 AM
Akon
0
I tried but I don't understand it. I'm new to this. I read the book but still can't understand it.
1st Apr 2017, 12:37 AM
Akon
- 1
this should get you started - write it, compile it, and run it :D
1st Apr 2017, 12:46 AM
Brandon
Brandon - avatar
- 2
#include <iostream> using namespace std; int main(){ int x=1; while(x==x){ cout<<"here's the code"; } }
1st Apr 2017, 12:45 AM
Brandon
Brandon - avatar