Question: this is in C++ In this exercise, you create a program that calculates the average of three test scores. The program should contain two value-returning
this is in C++
In this exercise, you create a program that calculates the average of three test scores. The program should contain two value-returning functions (main and calcAverage) and two void functions (getTestScores and displayAverage). The main function should call the void getTestScores function to get three test scores. The test scores may contain a decimal place. The main function then should call the value-returning calcAverage function to calculate and return the average of the three test scores. When the calcAverage function has completed its task, the main function should call the void displayAverage function to display the average of the three test scores on the screen. Display the average with one decimal place. Use a sentinel value to end the program.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
