from statistics import median n=input() print(median(map(lambda x: int(x), input().split())))