Question: Write a program that reads a student name followed by five test scores. The program should output the student name, the five test scores, and
Write a program that reads a student name followed by five test scores. The program should output the student name, the five test scores, and the average test score. Output the average test score with two decimal places. The program should also output the message "Failing" if the average is less than 70 and Passing" otherwise. If the average is 90 and up, the message "Excellent! " is outputted as well. The data to be read is stored in a file called test.txt.A sample input is: Bob Savage 87.50 89 65.75 37 98.50 In addition, include statements to exit the program if the input file does not exist as shown below: Cannot open the input file. The program terminates 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
