import statistics as stat input() print(stat.median(map(int,input().split())))