import statistics,math s=int(input()) s2=[int(i) for i in input().split()] s3=statistics.median(s2) print(s3)