f=lambda:int(input()) N,A=f()-1,f() c,p=1,print for _ in'1'*N:p(c);c+=f()>A p(c)