#include using namespace std; int main() { int H, W; cin >> H >> W; cout << "? 1 1" << endl; int tmp1; cin >> tmp1; if (tmp1 == 0) { cout << "! 1 1" << endl; return 0; } if (W == 1) { cout << "? 2 1" << endl; int tmp2; cin >> tmp2; int sa = tmp1 - tmp2; for (int i = 1; i <= H; ++i) { if (i * i - (i - 1) * (i - 1) == sa) { cout << "! " << i + 1 << " 1" << endl; return 0; } } } else { cout << "? 1 2" << endl; int tmp2; cin >> tmp2; int sa = tmp1 - tmp2; int x, y; if (sa < 0) x = 1; else { for (int i = 1; i <= W; ++i) { if (i * i - (i - 1) * (i - 1) == sa) { x = i + 1; break; } } } tmp1 -= (x - 1) * (x - 1); tmp1 = sqrt(tmp1); cout << "! " << tmp1 + 1 << " " << x << endl; return 0; } }