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 print(*list(accumulate(gt)), sep='\n')