d=[] for i in range(int(input()): d.append(int(input()) if len(d)%2==1: print(d[(len(d)+1)/2) else: print((d[len(d)/2]+d[len(d)/2+1])/2)