voidconnect(int i, int j){ int fi = find(i); int fj = find(j); if (fi != fj) fa[fi] = fj; }
doubledist(int i, int j){ return (x[i]-x[j])*(x[i]-x[j]) + (y[i]-y[j])*(y[i]-y[j]); } boolcheck(double k){ memset(fa, ~0, sizeof(fa)); for (int i = 1;i <= n; ++i) { for (int j = i+1;j <= n;++j) { if (dist(i, j) < 4*k*k) connect(i, j); } if (abs(y[i] - 100) < 2*k) connect(n+1, i); if (abs(y[i] + 100) < 2*k) connect(n+2, i); } returnfind(n+1) != find(n+2); }
intmain(){ ios_base::sync_with_stdio(0); cin.tie(0); cin >> n; for (int i = 1;i <= n; ++i) { cin >> x[i] >> y[i]; } double L = 0, R = 100, M; while (R-L > 1e-5) { M = (L+R)/2; if (check(M)) L = M; else R = M; } cout << fixed << setprecision(5) << M << endl; return0; }