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# (.NET Core 3.1.201) (judge verdict: Wrong Answer)

using System;
using System.Linq;
using System.Collections.Generic;
using static System.Console;
using System.Text;
using System.IO;
using static System.Math;
using System.Numerics;

namespace AtCoder
{
    class Program
    {
        static public long[] Sarray() { return ReadLine().Split().Select(long.Parse).ToArray(); }
        static public List<long> Slist() { return ReadLine().Split().Select(long.Parse).ToList(); }
        static public (T1 a, T2 b) Slice<T1, T2>()
        {
            var t = ReadLine().Split();
            return (
            (T1)Convert.ChangeType(t[0], typeof(T1)),
            (T2)Convert.ChangeType(t[1], typeof(T2)));
        }
        static long Mod = (long)1e9 + 7;
        static void Main(string[] args)
        {
            SetOut(new StreamWriter(OpenStandardOutput()) { AutoFlush = false });
            Solve();
            Out.Flush();
            Read();
        }
        static void Solve()
        {
            var N = Sarray()[0];
            var xy = new (long x, long y)[N];
            for(var i=0;i<N;++i)
                xy[i] = Slice<long, long>();
            double snorm((double x, double y) p1, (double x, double y) p2) =>
                (p1.x - p2.x) * (p1.x - p2.x) + (p1.y - p2.y) * (p1.y - p2.y);
            bool incircle((double x, double y) cc, double r, (double x, double y) p) =>
                 Sqrt(snorm(cc, p)) <= r + 0.0000001;

            if (N == 2)
            {
                WriteLine(Sqrt(snorm(xy[0], xy[1])) / 2.0);
                return;
            }
            var minr = double.MaxValue;
            for (var i = 0; i < N; ++i)
                for (var j = i + 1; j < N; ++j)
                    for (var k = j + 1; k < N; ++k)
                    {
                        var a2 = snorm(xy[j], xy[k]);
                        var b2 = snorm(xy[k], xy[i]);
                        var c2 = snorm(xy[i], xy[j]);
                        var e1 = a2 * (b2 + c2 - a2);
                        var e2 = b2 * (c2 + a2 - b2);
                        var e3 = c2 * (a2 + b2 - c2);
                        var cx = e1 * xy[i].x + e2 * xy[j].x + e3 * xy[k].x;
                        var cy = e1 * xy[i].y + e2 * xy[j].y + e3 * xy[k].y;
                        var cxy = (cx / (e1 + e2 + e3), cy / (e1 + e2 + e3));
                        var a = Sqrt(a2);
                        var b = Sqrt(b2);
                        var c = Sqrt(c2);
                        var r = a * b * c / Sqrt((a + b + c) * (-a + b + c) * (a - b + c) * (a + b - c));
                        var outside = false;
                        for (var l = 0; l < N; ++l)
                        {
                            if (!incircle(cxy, r, xy[l]))
                            {
                                outside = true;
                                break;
                            }
                        }
                        if (!outside)
                            minr = Min(minr, r);
                    }
            WriteLine(minr);
        }
    }
}