#include #include #include #include #include #include #include using namespace std; typedef long long ll; typedef pair P_; typedef pair P; int n; ll x[1000], y[1000]; bool del[1000]; int main(){ ios::sync_with_stdio(false); cin.tie(0); cout << setprecision(10) << fixed; cin >> n; for(int i = 0; i < n; i++) cin >> x[i] >> y[i]; vector

v; for(int i = 0; i < n; i++){ for(int j = i+1; j < n; j++){ ll m = (x[i]-x[j])*(x[i]-x[j]) + (y[i]-y[j])*(y[i]-y[j]); v.push_back(P(m, P_(i, j))); } } sort(v.begin(), v.end()); int ans = 0; for(auto p : v){ int i = p.second.first; int j = p.second.second; // cout << i << ' ' << j << endl; if(i == 0 && !del[j]){ ans++; del[j] = true; }else{ if((!del[i]) && (!del[j])){ del[i] = true; del[j] = true; } } } cout << ans << endl; }