N = int(input()) x = [int(i) for i in input().split()] x.sort() for i in range(N-1): x[-1] += int(x[i]/2) print(x[-1])