Assignment #3


For this assignment you will build on the previous assignment as well as your new found abilities to sort and take user input. This program will probably feel more like a real program to you. Basically, for this assignment I was you to create a grade book program using the students you developed in assignment #2. I will start the gradebook by calling the function (start-gradebook) with no arguments. You will present me with the following menu.

1. Add student
2. Add assignment grade
3. Add quiz grade
4. Add test grade
5. Set class participation grade
6. Print student data
7. Sort by name
8. Sort by average
9. Print listing
10. Quit

Option 1 should ask for a name and add a student with that name and no grades to the class (which you will maintain in a running fashion with a list. Option 2 asks for a student name and if the student is found asks for a grade to add to that student. Similarly for 3 and 4. For 5 it asks for the name and resets the class participation to the new value. 6 should ask for a students name and print out the information for that student in a reasonable fashion. 7 and 8 just reorder the list of students and you then use 9 to print the student names and final averages in the order they are currently in.

Extra Credit: Add options above 10 for removing grades or replacing grades of different types. Also, make it so you only write one sort function, but have it so it can sort in different ways depending on a comparator function that is passed to it.