#include using namespace std; using ll = long long; const int x_dir[] = {0, 1, 0, -1}; const int y_dir[] = {-1, 0, 1, 0}; int main() { ll n = 1e9; for (int i=0; i<30; ++i) { ll x = n/2; cout << x << endl; int r; cin >> r; switch(r) { case 0: n = x; break; case 1: case -1: return 0; } } return 0; }