n,*a=map(int,open(0).read().split());k=0 for i in range(1<