Question: Write a Program in Java in which you are given a list of marks over 5 subjects scored by n students. you need to sort
Write a Program in Java in which you are given a list of marks over 5 subjects scored by n students. you need to sort the student by the following rules. The student whose sum of marks will be highest must come at the top of the leaderboard Students whose total sum of marks are the same will be sorted alphabetically ascending by name In all other cases, student with lesser id will come before in the leaderboard.
Given Input:
n= 5
1 Noah 32 64 46 71 50
2 Alex 72 49 63 45 61
3 Sophia 98 87 84 92 96
4 Julie 81 79 77 84 73
5 Oliver 29 52 48 46 57
Output:
3 4 2 1 5
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
