from heapq import *

n = int(input())
v = list(map(int, input().split()))

h = []
for i in range(n):
    heappush(h, v[i])

for i in range(n-1):
    x, y = heappop(h), heappop(h)
    heappush(h, (x + y) / 2)

print(h[0]//1)