#include <iostream>

using namespace std;

int main () {
    int x, y, n = 199, alt;

    x = 0; y = n;
    while (1) {
        cout << x << " " << y << "\n";
        cout.flush ();
        cin >> alt;
        if (alt == 0)
            return 0;
        else
            if (alt < 0)
                x ++;
        else
            if (alt > 0)
                y --;
    }
    return 0;
}