//Kanoa Holden CS1A Chapter 3, P. 143 Q#3
//
/*******************************************************************************
*
* COMPUTE AVERAGE TEST SCORE
* _____________________________________________________________________________
* This program will calculate the average test score.
*
* Computation is based on the formula:
* average = score1 + score2 + score3 + score4 + score5 / 5.0
* _____________________________________________________________________________
* INPUT
* score1 : score of student 1
* score2 : score of student 2
* score3 : score of student 3
* score4 : score of student 4
* score5 : score of student 5
*
* OUTPUT
* average = average of students test scores
*
******************************************************************************/
#include <iostream>
#include <iomanip>
using namespace std;
int main() {
// Declare variables of test scores
double score1, score2, score3, score4, score5;
// Ask the user to input five test scores
cout << "\nEnter test score 1: ";
cin >> score1;
cout << "\nEnter test score 2: ";
cin >> score2;
cout << "\nEnter test score 3: ";
cin >> score3;
cout << "\nEnter test score 4: ";
cin >> score4;
cout << "\nEnter test score 5: ";
cin >> score5;
// Calculate the average score
double average = (score1 + score2 + score3 + score4 + score5) / 5.0;
// Display the average score
cout << fixed << setprecision(1);
cout << "\nThe average test score is: " << average << endl;
return 0;
}