Question: In this exercise, you will build a simple Java application that calculates the weekly average of temperatures and then converts it from Fahrenheit to Celsius.

In this exercise, you will build a simple Java application that calculates the weekly average of temperatures and then converts it from Fahrenheit to Celsius.

1. When the application starts, it asks for Mondays temperature

2. After you enter Mondays temperature, another dialog box appears, asking for Tuesdays temperature

3. This process will continue for the other days in a week, with the last dialog box asking for Sundays temperature

4. Afterwards, the program calculates the weekly average and converts it to Celsius. It then displays the results

SPECIFICATIONS

1. Use a double array to store the seven daily temperature values.

2. Besides the main() method, write the following three methods. The data types of your parameter(s) and return value, if any, must match what are described in the following table. That is, if a double value is specified here, declare your parameter/return type as such:

In this exercise, you will build a simple Java application that calculates

3. The weekly average is a simple average of the seven daily ones, i.e., total divided by 7

4. The formula for Fahrenheit to Celsius conversion is: (F -32)(5)/9 =C

6. Note that the Fahrenheit and Celcius output are precise to two decimal places. To perform this formatting, use the DecimalFormat class. Declare a DecimalFormat object and use its related method if necessary.

7. You must use method names exactly as listed above. Failure to do so may cause point deduction. You may use names of your choice for local variables in the methods. However, you should follow the proper Java naming convention.

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!