import statistics N = int(input()) A_list = list(map(int, input().split())) print((statistics.median(A_list)))