#include <bits/stdc++.h>
using namespace std;

#define all(x) begin(x), end(x)
#define sz(x) (int)(x).size()

using ll = long long;
using ld = long double;

int main() {
	ios_base::sync_with_stdio(false);
	cin.tie(nullptr);
	ll t;
	cin >> t;
	cout << fixed << setprecision(0);
	for (ll i = 0; i < t; i++) {
		cout << "? 50 49\n? 49 48\n! 1" << endl;
	}
}
