#include using namespace std; void fast_io() { ios_base::sync_with_stdio(false); cin.tie(nullptr); } long long query(int x, int y) { cout << "1 " << x << " " << y << endl; long long a; cin >> a; return a; } int main() { fast_io(); int n; cin >> n; int xl = -1e9 - 1, xr = 1e9 + 1; while (xl + 1 < xr) { int xm = (xl + xr) / 2; long long q1 = query(xm, 0) - query(xm + 1, 0); if (q1 == 0) { xr = xm; break; } else if (q1 > 0) { xl = xm; } else { xr = xm; } } int yl = -1e9 - 1, yr = 1e9 + 1; while (yl + 1 < yr) { int ym = (yl + yr) / 2; long long q2 = query(0, ym) - query(0, ym + 1); if (q2 == 0) { yr = ym; break; } else if (q2 > 0) { yl = ym; } else { yr = ym; } } cout << "2 " << xr << " " << yr << endl; }