from itertools import combinations, permutations
N = int(input())
#N,K = map(int,input().split())
#N = int(input())
V = list(map(int,input().split()))
s=0
S=[]
for C in combinations(V,2):
    n=N
    v=V.copy()
    v.remove(C[0])
    v.remove(C[1])
    s=(C[0]+C[1])/2**(n-1)
    n-=2
    #print(C,s)
    for D in combinations(v,len(v)):
        for i in range(len(v)):

            s+=D[i]/2**n
            n-=1
            #print(D,s)
        S.append(s)
print(max(S))
