Question: C7.1 Test Score Statistics: Write a program that asks the user to enter 5 test scores (data type = double) into an array. The program

C7.1 Test Score Statistics:

Write a program that asks the user to enter 5 test scores (data type = double) into an array. The program should calculate and display:

The average of the 5 test scores

The largest test score stored in the array

The smallest test score stored in the array.

Practice using functions that you learned in Chapter 6 to make your program more modular and easier to read. Here are the function prototypes to use:

// Function Prototypes

void printProgramPurpose();

void getTestScores (double testScores [], int numTests);

double calcAverageTestScore (double testScores [], int numTests);

double getLargestTestScore (double testScores [], int numTests);

double getSmallestTestScore (double testScores [], int numTests);

void printResults (double averageTestScore,

double largestTestScore,

double smallestTestScore);

Input Validation: Do not accept test scores less than 0 or greater than 100.

Include several test runs of the program to show successful runs of your program, with both valid and invalid data (to show that you are checking for invalid data)

Please ensure the program is well designed and follows accepted style guidelines (e.g. variable naming, indentation, spacing).

Please ensure the program is well documented, including the overall purpose of the program and documenting all the major sections of the code.

NEW: Please ensure your output includes a line that identifies you.

In C++

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!