#include using namespace std; typedef long long ll; // 質問クエリ int ask(int x, int y, int z){ int d; cout << "?" << " " << x << " " << y << " " << z << endl; cin >> d; return d; } // 回答クエリ void answer(int x, int y, int z){ cout << "!" << " " << x << " " << y << " " << z << endl; } ll X[3]; // [from, to) ll findMin(ll from, ll to, int idx){ for(; to - from > 1;){ ll mid = (from + to) / 2; X[idx] = mid - 1; ll d1 = ask(X[0], X[1], X[2]); X[idx] = mid; ll d2 = ask(X[0], X[1], X[2]); (d1 > d2 ? from : to) = mid; } return from; } int main(){ cin.tie(0); ios::sync_with_stdio(false); #ifdef LOCAL std::ifstream in("in"); std::cin.rdbuf(in.rdbuf()); #endif for(int i = 0; i < 3; i++){ X[i] = findMin(-150, 151, i); } answer(X[0], X[1], X[2]); }