[Solved] Create a java program that asks the user how many students they have in a classroom

$25

File Name: Create_a_java_program_that_asks_the_user_how_many_students_they_have_in_a_classroom.zip
File Size: 781.86 KB

SKU: [Solved] Create a java program that asks the user how many students they have in a classroom Category: Tag:
5/5 - (1 vote)

5/5 – (3 votes)

Create a java program that asks the user how many students they have in a classroom. Then, using a while loop, which asks the user to enter the grades (out of 100) for all students in the classroom, one at a time. Finally, the program should calculate the sum and average of the grades and print it out.

Sample Run1

Enter number of students: 3

Enter mark for student 1: 56

Enter mark for student 2: 45

Enter mark for student 3: 66

Output1: Sum = 167 and Average = 55.67

Sample Run2

Enter number of students: 6

Enter mark for student 1: 86

Enter mark for student 2: 15

Enter mark for student 3: 69

Enter mark for student 4: 77

Enter mark for student 5: 45

Enter mark for student 6: 90

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] Create a java program that asks the user how many students they have in a classroom
$25