We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
i think that when you assigned marksheet+=[ [name,score] ] this line and so in the for loop for a,c in sorted(marksheet):.here 'a' is for name and 'c' is for score.So you are comparing if the score matches then you print the name
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Nested Lists
You are viewing a single comment's thread. Return to all comments →
i think that when you assigned marksheet+=[ [name,score] ] this line and so in the for loop for a,c in sorted(marksheet):.here 'a' is for name and 'c' is for score.So you are comparing if the score matches then you print the name