I have the following assignment:
A GPA, or Grade point Average, is calculated by summing the grade points earned in a student’s courses and then dividing by the total units. The grade points for an individual course are calculated by multiplying the units for that course by the appropriate factor depending upon the grade received:
A receives 4 grade points
B receives 3 grade points
C receives 2 grade points
D receives 1 grade point
F receives 0 grade point
Your program will have a for loop to calculate multiple GPAs and a for loop to collect individual grades (i.e. a nested for loop).
Any ideas about how to approach this? It seems to me that there has to also be a while loop involved, since we don't know how many courses the user needs to input. Is that true? Is there a way to implement something like a sentinel using only for loops?