#include using namespace std; using P = pair; using T = tuple; int main() { int n; cin >> n; vector

ps(n); for(auto &[x, y] : ps) cin >> x >> y; auto distance = [&](auto p, auto p2) -> long long { auto[x, y] = p; auto[x2, y2] = p2; long long dx = x - x2; long long dy = y - y2; return dx * dx + dy * dy; }; priority_queue, greater> que; for(int i = 0; i < n; ++i) { for(int j = i + 1; j < n; ++j) { que.emplace(distance(ps[i], ps[j]), i, j); } } int ans = 0; vector burst(n); while(!que.empty()) { auto[d, i, j] = que.top(); que.pop(); if(burst[i] || burst[j]) continue; if(i == 0) { burst[j] = true; ans++; } else { burst[i] = true; burst[j] = true; } } cout << ans << '\n'; return 0; }