You are viewing a single comment's thread. Return to all comments →
Simple solution
students = [] for _ in range(int(input())): name = input() score = float(input()) students.append([name,score]) second_high = sorted(set([i[1] for i in students]))[1] print("\n".join(sorted([i[0] for i in students if i[1] == second_high])))
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 →
Simple solution