# question

• 03-05-2012
kooldude220
question
Assume the following:
(1) The number of the students in your class is a random number between [131, 162].
(2) Every student has 3 exams, and each exam grade is a random integer between [10, 100].
(3) A student's total grade is the average of the three exam grades.
(4) If the total grade is in [10, 59], the letter grade is F; If the total grade is in [60, 74], the letter grade is C;
If the total grade is in [75, 84], the letter grade is B; If the total grade is in [85, 100], the letter grade is A.

Requirements:

(1) you need to use a 2-dimensional array to store all the grades for the students. For eachs student, you need to
store her student number (a number ranging from 1 to the total number of student), her grades for three exams, and

(2) You first need to print the maximum and minimum grades for each exam, and the corresponding student number.

Output can look like:

Exam 1 maximum Student number
100 24

Exam 2 minimum Student number
10 165

(3) You need to sort all the students based upon their final grades in the descending order. Then print the
sorted list in the following format (I show a sample output below):

24 100 A
17 98 A
160 95 A

(4) Finally, you need to add a student into the list if the class is not full yet (maximum size is always 162). Again, you need to randomly
generate this student's grades for 3 exams and calculate her total. When you insert, make sure the sorted order
on the total grade is obeyed.

Then you need to print out the new list (in the same format above). On your print out, please put a "start sign"
to indicate which one is the new student.

At last, please use getchar() at the end of main function so that the output window will stay.