DECODE11 - Editorial

PROBLEM LINK:

Practice

Author: Manas Rawat
Tester: Aagam Jain
Editorialist: Manas Rawat

DIFFICULTY:

CAKEWALK

PROBLEM:

You have been given a correct answer and the answer of the students as well. You have to tell the Roll Number of student(s) who have scored the highest marks.

QUICK EXPLANATION:

This is a very simple string matching question. You have to take the first string as reference and you have to compare the others strings while also keeping in mind the maximum marks obtained by any student. In case a new highest marks is obtained you have to clear the list and then add the students. If the latest marks is equal to the previous high then just add the student to the list.

SOLUTIONS:

Solution can be found here.