Question: C++ program that will have the user enter Celsius temperature readings for each day of the week and then display a report showing both the
C++ program that will have the user enter Celsius temperature readings for each day of the week and then display a report showing both the Celsius and Fahrenheit temperatures for each day entered. This program requires the use of arrays. 
Prompting: For this lab, rather than prompt the user Enter temperature for Day 1: , use the actual day in the prompt, e.g. Enter the temperature for Sunday: . You are required to use a loop and GetValidDouble() to produce this prompt and get user input respectively.
Converting an Integer to a Day String: Write a function that will accept an integer as an argument and return a string. If the argument is in the range 1 to 7 inclusively, return the corresponding name for the day. For example, an argument of 1 should return Sunday, an argument of 2 should return Monday, etc. Although you could use an ifelse chain or a switch, the trick to doing this very efficiently is to implement an array of strings that contains the names of the days as elements and to use the argument as an index to find the right day. If the argument is outside of the range 1 to 7, return an error message instead.
Range Validation: The lowest natural surface temperature on Earth is 89.2C. It was measured on 21 July 1983 at Vostok Research Station in the Antarctic.1 The highest surface temperature recorded is 57.8C, in Aziziya, Libya on 13 September 19222. Given these values, the temperatures the user enters should fall between the range 90.0C and +60.0C. Do not accept an input value outside of that range.
TEMPERATURE REPORTER lease enter the temperature for each day of the week elsius temperature for Sunday: -108.8 Inualid input. Please try again and enter a value between -90 and 60. 9.9 Inualid input. Please try again and enter a value between -90 and 60. OT! Invalid input. Please try again and enter a numeric value 5.5 Celsius temperature for Monday: _
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
