#include #define rep(i,n) for(int i=0;i<(n);i++) using namespace std; const int INF=1<<29; map,int> memo; int ask(int x,int y){ if(memo.count({x,y})>0) return memo[{x,y}]; printf("%d %d\n",x,y); fflush(stdout); int res; scanf("%d",&res); memo[{x,y}]=res; if(res==0) exit(0); return res; } int main(){ int x0,y0; int lo=0,hi=1e5; while(hi-lo>2){ int mi1=(2*lo+hi)/3,mi2=(lo+2*hi)/3; if(ask(mi1,0)2){ int mi1=(2*lo+hi)/3,mi2=(lo+2*hi)/3; if(ask(x0,mi1)