import sys def f(x,y): print(x,y) sys.stdout.flush() A=int(input()) if A==0:exit() return A a=f(0,0) b=f(0,10**10) x=(a+b-10**10)//2 f(x,a-x)