https://www.acmicpc.net/problem/7568
입력된 몸무게 x, 키 y를 비교하여 등수를 매기면 된다.
list에 (x,y)로 저장 후 조건문을 통해 등수를 비교하면 된다.
import sys
input = sys.stdin.readline
# 몸무게(x)와 키(y)를 arr에 저장
arr = []
for _ in range(int(input())):
x,y = map(int,input().split())
arr.append((x,y))
for i in arr:
res = 1 # 랭킹 1로 고정
for j in arr:
if i[0] < j[0] and i[1] < j[1]: # 몸무게, 키가 다음 사람보다 작으면
res += 1 # 등수 +1
print(res, end=' ')