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.
if name == 'main':
first_multiple_input = input().rstrip().split()
n = int(first_multiple_input[0])
m = int(first_multiple_input[1])
arr = []
for _ in range(n):
arr.append(list(map(int, input().rstrip().split())))
k = int(input().strip())
val = sorted(arr, key=lambda x: x[k])
[print(*i) for i in val]
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Athlete Sort
You are viewing a single comment's thread. Return to all comments →
if name == 'main': first_multiple_input = input().rstrip().split()