import statistics n = int(input()) a = map(int,input().split()) b = statistics.median(a) print(b)