You are viewing a single comment's thread. Return to all comments →
With dictionaries
lista = {} for _ in range(int(input())): name, score = input(), float(input()) if score not in lista.keys(): lista[score] = [name] else: lista[score].append(name) print('\n'.join(sorted(sorted(lista.items())[1][1])))
Nested Lists
You are viewing a single comment's thread. Return to all comments →
With dictionaries