l=1 r=10**9 while True: m=(l+r+1)//2 print(m,flush=True) t=int(input()) if t==1: exit() r=m-1