import numpy as np

n = int(input())
v = np.array(list(map(int,input().split())))
v_sort = np.sort(v)
temp = 0

for index in range(n-1):
  temp = (v_sort[0]+v_sort[1])/2
  v_sort = np.delete(v_sort,0)
  v_sort = np.delete(v_sort,0)
  v_sort = np.append(v_sort,temp)
  v_sort = np.sort(v_sort)

print(int(v_sort[0]))