1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
NARA [144]
3 years ago
14

Write a program and flowchart. The program should ask the user for the average temperature in each of the last 12 months. After

the user has entered the temperatures, the program should display them. Use a "for" loop to ask for the data, and use another "for" loop to display the data. Store the data in an array called "temperature."Here is what the output looks like.

Computers and Technology
1 answer:
Afina-wow [57]3 years ago
5 0

#First we define the variables to house the temperatures

#temp is an empty array that will be used to store the temperature

Temp = []

#The months is defined as stated below

months = 12

#Ask the user for the temperature input and unit if possible

print("Kindly enter the temperature here")

#the program enter loop to get the temperatures.

for x in range(months):  

   InitTemp = str(input("Kindly add the unit behind the number .eg C for celcius"))

   Temp.append(InitTemp)

j=0

for x in range(len(Temp)):  

   j=j+1

   print("The Temperature is", " ", Temp[x], "for the ", j, "Month" )

#there is an attached photo for the flowchart

You might be interested in
This question is for one of my classes I am in right now, and the question is:
suter [353]

Answer:

I will respond by saying the destination is not the most important , the journey is.

Explanation:

8 0
3 years ago
HIGH POINTS!!! <br>List the creation date of each gaming console to exist.​
ANEK [815]

Answer:

Explanation:

The original Xbox: November 15, 2001

The original PS1: December 1, 1994

Xbox 360: November 22, 2005

Ps2: March 4, 2000

Ps3: November 11, 2006

Xbox One: November 22, 2013

Ps4: November 15, 2013

Nintendo Ds: November 21, 2004

Nintendo 3ds: February 26, 2011

Gameboy: April 21, 1989

Nintendo Switch: March 3, 2017

7 0
3 years ago
What's the problem with this code ?
Svet_ta [14]
Hi,

I changed your program using some of the concepts you were trying to use. Hopefully you can see how it works:

#include <string>
#include <iostream>
#include <sstream>
#include <vector>
#include <algorithm>

using namespace std;

int main()
{
   short T;
   cin >> T;
   cin.ignore();

   string str[100];

   for(int i=0; i<T; i++)
   {
      getline(cin, str[i]);
   }

   for (int i = 0; i < T; i++)
   {
      stringstream ss(str[i]);
      string tmp;
      vector<string> v;

      while (ss >> tmp)
      {
          // Let's capitalize it before storing in the vector
          if (!tmp.empty())
          {
              transform(begin(tmp), end(tmp), std::begin(tmp), ::tolower);
              tmp[0] = toupper(tmp[0]);
           }
           v.push_back(tmp);
        }

        if (v.size() == 1)
        {
           cout << v[0] << endl;
        }
        else if (v.size() == 2)
        {
           cout << v[0][0] << ". "  << v[1] << endl;
        }
        else
        {
            cout << v[0][0] << ". " << v[1][0] << ". " << v[2] << endl;
        }
    }

     return 0;
}

4 0
2 years ago
The exception of MS Access 2007 and above files is _ and older version are _ files ​
ohaa [14]

Answer:

Never heard of that kind of software, but I think it's an old file.

4 0
2 years ago
The list of abbreviations, punctuation, symbols, typefaces, and instructional notes that appears at the beginning of the ICD and
Ilia_Sergeevich [38]

Answer: Conventions

Explanation: Convention is the writing activity with the components like punctuation,grammar,symbols,note etc to make the written content understandable and clear. This feature is used because people can understand the meaning of content read by them without initializing it later.

As soon as the reader finishing the reading the information should be clear in his/her mind so that they don't have to figure it out after reading.Convention enhances the value of reading and learning by it's feature .

4 0
3 years ago
Other questions:
  • What software refers to the on authorized and illegal duplication or sale of software
    10·1 answer
  • The word computer consists of 64 bits, which is equivalent to _____ bytes.
    5·1 answer
  • _____ software can help a company manage security, enforce corporate strategies, and control downloads and content streaming fro
    11·1 answer
  • 110101111.11011 to decimal (base 10)
    6·1 answer
  • Stealing passwords by using software code to run through various password schemes with numbers, symbols, capital letters, and ch
    6·1 answer
  • Read the excerpt from The Code Book. Other attacks include the use of viruses and Trojan horses. Eve might design a virus that i
    13·1 answer
  • C++
    11·2 answers
  • Design a full adder circuit using NAND gates only (input : A, B, Cin and output = S, Cout).
    5·1 answer
  • (Convert milliseconds to hours, minutes, and seconds) Write a function that converts milliseconds to hours, minutes, and seconds
    12·1 answer
  • WHICH PROGRAMMING LANGUAGES ARE THE BEST AND COMPATIBLE FOR 3D PRINTERS?
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!