#include using namespace std; int query(int a, int b) { cout << a << " " << b << endl; cin >> a; return a; } int main() { #ifndef ONLINE_JUDGE //freopen("debug", "r", stdin); #endif // ONLINE_JUDGE int N = 200; int j = 0; for(int i=0; i<200; i++) { while(true) { int a = query(i, j); if(a == 0) return 0; if(a > 0) break; j++; } } return 0; }