Question: JAVA Write a program that calculates the average of a series of three test scores for a student. After the average is displayed, it should
JAVA
Write a program that calculates the average of a series of three test scores for a student. After the average is displayed, it should ask the user if he or she wants to average another set of test scores. The program repeats as long as the user enters Y for yes. You must use do... while loop for this.
The output of the program should look like following:
C. C:\Windows\system32\cmd.exe Enter score #1: 89 Enter score #2: 90 Enter score #3: 97 Average: 92.0 Would you like to average another set of test scores? Enter Y for yes or N for no: Y Enter score #1: 75 Enter score #2: 95.5 Enter score #3: 55.8 Average: 75.4 Would you like to average another set of test scores? Enter Y for yes or N for no: N Press any key to continue
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
