Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Use the steps below to write a C++ program to store grades for a class. There are 5 students in the class and each student

Use the steps below to write a C++ program to store grades for a class. There are 5 students in the class and each student has five grades during the tern. Name the program ClassGrades

Write a type declaration that will store these grades and student names. Make sure grades are between 0 and 100.

Write a function LoadGrades() that ask the user for the five grades for each student and stores them in the array declared in (A).

Write a function DisplayGrades() that displays a table of the data n the array:

Write a function StuAvg() that displays a list of student averages similar to:

Write a function TestAve() that displays the averages on each test:

Write a menu-driver program that allows the user to select from the four functions above.

Below is an example of the program in action

Welcome to the Class Grade program. Choose from the following menu items: 1 - Load Grades 2 - Display Grades 3 - Display Student Average 4 - Display Test Average 1

Enter the student name and their 5 test grades. Enter name for student 1 _______________________________ Student Name: Bob Enter the five test scores 85 98 56 78 69 Enter name for student 2 _______________________________ Student Name: Mary Enter the five test scores 45 75 65 85 79 Enter name for student 3 _______________________________ Student Name: Sue Enter the five test scores 98 105 Score must be between 0 and 100. Please re-enter a score.100 85 96 97 Enter name for student 4 _______________________________ Student Name: Dave Enter the five test scores 65 45 68 72 187 Score must be between 0 and 100. Please re-enter a score.87 Enter name for student 5 _______________________________ Student Name: Bill Enter the five test scores 85 86 89 78 92 Welcome to the Class Grade program. Choose from the following menu items: 1 - Load Grades 2 - Display Grades 3 - Display Student Average 4 - Display Test Average 2

TEST STUDENT 1 2 3 4 5 Bob 85 98 56 78 69 Mary 45 75 65 85 79 Sue 98 100 85 96 97 Dave 65 45 68 72 87 Bill 85 86 89 78 92 Welcome to the Class Grade program. Choose from the following menu items: 1 - Load Grades 2 - Display Grades 3 - Display Student Average 4 - Display Test Average 3

STUDENT AVERAGE Bob 77.2 Mary 69.8 Sue 95.2 Dave 67.4 Bill 86 Welcome to the Class Grade program. Choose from the following menu items: 1 - Load Grades 2 - Display Grades 3 - Display Student Average 4 - Display Test Average 4

TEST AVERAGE 1 75.6 2 80.8 3 72.6 4 81.8 5 84.8 Welcome to the Class Grade program. Choose from the following menu items: 1 - Load Grades 2 - Display Grades 3 - Display Student Average 4 - Display Test Average

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Advances In Knowledge Discovery In Databases

Authors: Animesh Adhikari, Jhimli Adhikari

1st Edition

3319132121, 9783319132129

More Books

Students also viewed these Databases questions

Question

Differentiate the function. r(z) = 2-8 - 21/2 r'(z) =

Answered: 1 week ago