#include #define ALL(x) (x).begin(), (x).end() #define LB(v, x) (int)(lower_bound(ALL(v), x) - (v).begin()) #define UQ(v) sort(ALL(v)), (v).erase(unique(ALL(v)), (v).end()) #define IO ios::sync_with_stdio(false), cin.tie(nullptr); #define chmax(a, b) (a) = (a) < (b) ? (b) : (a) #define chmin(a, b) (a) = (a) < (b) ? (a) : (b) using namespace std; using ll = long long; const int INF = 1e9 + 10; const ll INFL = 4e18; int main() { auto solve = [&](ll cx, vector> xy) -> tuple { int n = ssize(xy) / 2; vector> arg; for (auto [x, y] : xy) { arg.emplace_back(atan2(y, x - cx), x, y); arg.emplace_back(atan2(y, x - cx) + numbers::pi + 2, x, y); } sort(ALL(arg)); for (int i = 0; i < 2 * n; i++) { int j = LB(arg, make_tuple(get<0>(arg[i]) + numbers::pi, -INFL, -INFL)); if (j - i == n) { auto [t, x, y] = arg[i]; return make_tuple(y, x - cx, -y * cx); } } return make_tuple(0, 0, 0); }; int N; cin >> N; vector> XY(2 * N); for (auto& [x, y] : XY) cin >> x >> y, x *= 2, y *= 2; map cnt; for (auto [x, y] : XY) cnt[x]++; ll sum = 0; for (int i = -10; i <= 10; i += 2) { sum += cnt[i]; if (sum >= N) { { auto [a, b, c] = solve(i + 1, XY); if (a != 0 || b != 0 || c != 0) { ll g = gcd(abs(a), gcd(abs(b), abs(c))); a /= g, b /= g, c /= g; cout << a << ' ' << b << ' ' << c << endl; return 0; } } { auto [a, b, c] = solve(i - 1, XY); if (a != 0 || b != 0 || c != 0) { ll g = gcd(abs(a), gcd(abs(b), abs(c))); a /= g, b /= g, c /= g; cout << a << ' ' << b << ' ' << c << endl; return 0; } } } } }