Question: Write a program that asks the user for the number of students in a class. Use a for loop to iterate through each student .

Write a program that asks the user for the number of students in a class. Use a for loop to iterate through each student . Use a while loop to get as many scores as the user wants for each student until -1 is entered. Calculate and display the name, sum , and average score for each student. Finally, display the name and score of the student with highest score. For example : Tom has 5 scores : total scores is 340 and average is 68 Lina has 3 scores: total scores is 200 and average is 66.7 Tom has the highest total score of 340 Note: no arrays or ArrayList are allowed ; only loops and variables . If you have time , write the output to a file. +

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!