N = 10 ** 9 M = 30 for i in range(M): N -= 1 N = -(-N // 2) print(N, flush = True) r = int(input()) if r == 1: break if r == -1: N // 0