using System;
using System.Collections.Generic;
using System.Linq;

class Progaram
{
    static double Saiki(List<double> vs)
    {
        if (vs.Count == 1) return vs[0];
        if (vs.Count == 3)
        {
            if (vs[2] - vs[1] > vs[1] - vs[0])
            {
                return (vs[2] + (vs[0] + vs[1]) / 2) / 2;
            }
            else
            {
                return (vs[0] + (vs[1] + vs[2]) / 2) / 2;
            }
        }

        var newVs = new List<double>();
        for (var i = 0; vs.Count / 2 > i; i++)
        {
            newVs.Add((vs[0] + vs[vs.Count - 1]) / 2.0);
            vs.RemoveAt(0);
            vs.RemoveAt(vs.Count - 1);
        }
        if (vs.Count == 1) newVs.Add(vs[0]);
        return Saiki(newVs.OrderBy(x => x).ToList());
    }

    static void Main(string[] args)
    {
        var n = int.Parse(Console.ReadLine());
        var vs = Console.ReadLine().Split(' ')
            .Select(x => double.Parse(x)).OrderBy(x => x).ToList();
        Console.WriteLine(Saiki(vs));
    }
}
