Question: Exercise 4a). Write a program that creates two double variables called Fahrenheit and Celsius and that assigns the value 39 to the variable Celsius. The

Exercise 4a). Write a program that creates two double variables called Fahrenheit and Celsius and that assigns the value 39 to the variable Celsius. The program then computes the equivalent temperature in degrees Fahrenheit and assigns this value to a variable called Fahrenheit. (Find the formula on the Web.) The program then writes the correct result in the form [3 marks] 39.0 C = .. F. Change the program to have a value of -7.5 Celsius. Include both the outputs in this report. Do not concern yourself with controlling the display of the decimal point. Solution (program):

Output (2 output)

Exercise 4b). Write a program that creates two double variables called Fahrenheit and Celsius and that assigns the value 77.5 to the variable Fahrenheit. The program then computes the equivalent temperature in degrees Celsius and assigns this value to a variable called Celsius. (Find the formula on the Web.) The program then writes the correct result in the form [3 marks] 77.5 F = .. C. Change the program to have a value of 45.0 Fahrenheit. Include both the outputs in this report. Do not concern yourself with controlling the display of the decimal point. Solution (program):

Output (2 output)

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!