#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #define rep(x, to) for (int x = 0; x < (to); x++) #define REP(x, a, to) for (int x = (a); x < (to); x++) #define foreach(itr, x) for (typeof((x).begin()) itr = (x).begin(); itr != (x).end(); itr++) #define EPS (1e-14) using namespace std; typedef long long ll; typedef pair PII; typedef pair PLL; typedef complex Complex; typedef vector< vector > Mat; int main() { int mn = 1; int mx = 1e+9 + 7; while (mx - mn > 1) { int mid = (mn + mx) / 2; cout << "? " << mid << endl; int x; cin >> x; if (x > 0) { mn = mid; } else { mx = mid; } } cout << "! " << mn << endl; return 0; }