Problem:
Score : 600 points

Problem Statement

Given are N points (x_i, y_i) in a two-dimensional plane.

Find the minimum radius of a circle such that all the points are inside or on it.

Constraints

2 \leq N \leq 50

0 \leq x_i \leq 1000

0 \leq y_i \leq 1000

The given N points are all different.

The values in input are all integers.

Input

Input is given from Standard Input in the following format:

N
x_1 y_1
:
x_N y_N

Output

Print the minimum radius of a circle such that all the N points are inside or on it.

Your output will be considered correct if the absolute or relative error from our answer is at most 10^{-6}.

Sample Input 1

2
0 0
1 0

Sample Output 1

0.500000000000000000

Both points are contained in the circle centered at (0.5,0) with a radius of 0.5.

Sample Input 2

3
0 0
0 1
1 0

Sample Output 2

0.707106781186497524

Sample Input 3

10
10 9
5 9
2 0
0 0
2 7
3 3
2 5
10 0
3 7
1 9

Sample Output 3

6.726812023536805158

If the absolute or relative error from our answer is at most 10^{-6}, the output will be considered correct.

Solution in C++14 (GCC 5.4.1) (judge verdict: Accepted)

#include <cstdio>
#include <algorithm>
#include <vector>
#include <cstring>
#include <numeric>
#include <cassert>
#include <cmath>
#include <map>
#include <set>

using namespace std;
typedef long long LL;
typedef double LD;
typedef pair<LD, LD> PLD;
typedef pair<PLD, PLD> PPLD;

#define FOR(k,a,b) for(int k(a); k < (b); ++k)
#define FORD(k,a,b) for(int k(b-1); k >= (a); --k)
#define REP(k,a) for(int k=0; k < (a); ++k)
#define ABS(a) ((a)>0?(a):-(a))
#define EPS 1e-9
#define P45 acos(0.0)/2
#define P90 acos(0.0)

LD cross(PLD a, PLD b) { return a.first * b.second - a.second * b.first; }
LD area2(PLD a, PLD b, PLD c) { return cross(a, b) + cross(b, c) + cross(c, a); }

struct CIRCLE
{
	LD x, y, R;
	CIRCLE() {}
	CIRCLE(LD _x, LD _y, LD _R) : x(_x), y(_y), R(_R) {}
	void Read()
	{
		double _x, _y;
		scanf("%lf %lf", &_x, &_y);
		x = _x, y = _y, R = -1;
	}

	PPLD InterSection(const CIRCLE& other)
	{
		LD lx = x, ly = y, lR = R, ox = other.x, oy = other.y, oR = other.R;
		LD d = (lx - ox)*(lx - ox) + (ly - oy)*(ly - oy);
		d = sqrt(d);
		if (ABS(lR + oR - d) < EPS)
			return PPLD(PLD((x + other.x) / 2, (y + other.y) / 2), PLD(x, y));
		if (d < lR + oR)
		{
			LD a = (lR * lR - oR*oR + d*d) / (2.0*d);
			LD h = sqrt(lR*lR - a*a);
			PLD tp1(lx + a*(ox - lx) / d, ly + a*(oy - ly) / d);
			PLD p1(tp1.first + h*(oy - ly) / d, tp1.second - h*(ox - lx) / d);
			PLD p2(tp1.first - h*(oy - ly) / d, tp1.second + h*(ox - lx) / d);
			return PPLD(p1, p2);
		}
		return PPLD(PLD(x, y), PLD(x, y));
	}	
	bool IsIn(const PLD& p) const
	{
		return ABS((p.first - x)*(p.first - x) + (p.second - y)*(p.second - y)) <   R * R + EPS;
	}
};


int main() {
	int N, M;
	scanf("%d", &N);
	M = N;
	vector<CIRCLE> v(N);
	REP(i, N)
		v[i].Read();
	LD lo = 0, hi = 2000;
	while (ABS(hi - lo) > 0.0000001)
	{
		LD actR = (hi + lo) / 2;
		REP(i, N)
			v[i].R = actR;
		int mx = 0;
		REP(i, N) FOR(j,i+1,N)
		{
			PPLD ip = v[i].InterSection(v[j]);
			CIRCLE c1,c2;
			c1.x = ip.first.first, c1.y = ip.first.second, c1.R = actR;
			int db1 = 0, db2 = 0;
			REP(k, N)
			{
				if (c1.IsIn(make_pair(v[k].x, v[k].y)))
					++db1;
			}
			c2.x = ip.second.first, c2.y = ip.second.second, c2.R = actR;
			REP(k, N)
			{
				if (c2.IsIn(make_pair(v[k].x, v[k].y)))
					++db2;
			}
			mx = max<int>(max<int>(db1, db2),mx);
		}
		if (mx >= M)
			hi = actR;
		else
			lo = actR;
	}
	printf("%.10lf\n", lo);
	return 0;
}