Write a C program using arrays and any loop statements that asks the user to enter the number of students. For each student, enter the number of courses. The user should enter the students ID number and the marks for each course. Compute and display the total and average of the students marks.
Sample Output:
Enter the number of students: 2
Enter Student ID no. 1: 082367
Enter the number of courses: 2
Enter the mark for course 1: 80
Enter the mark for course 2: 80
Total marks = 160
Average = 80
Enter Student ID No. 2: 12345
Enter the number of courses: 3
Enter mark for course 1 : 80
Enter mark for course 2 : 90
Enter mark for course 3 : 85
Total Marks = 255
Average = 85
C program using loop and array
Write a C program using arrays and any loop statements that asks the user to enter the number of students. For each student, enter the number of courses. The user should enter the students ID number and the marks for each course. Compute and display the total and average of the students marks.
Sample Output:
Enter the number of students: 2
Enter Student ID no. 1: 082367
Enter the number of courses: 2
Enter the mark for course 1: 80
Enter the mark for course 2: 80
Total marks = 160
Average = 80
Enter Student ID No. 2: 12345
Enter the number of courses: 3
Enter mark for course 1 : 80
Enter mark for course 2 : 90
Enter mark for course 3 : 85
Total Marks = 255
Average = 85
Profile Answers by Mohammed Mahmood Almahdi Questions by Mohammed Mahmood Almahdi
Questions by Mohammed Mahmood Almahdi
This Question is not yet answered!
Related Answered Questions
Related Open Questions