from itertools import accumulate N = int(input()) A = [int(input()) for _ in range(N)] gt = [1 if a > A[0] else 0 for a in A] gt[0]+=1 ans = list(accumulate(gt)) print(*ans, sep='\n')