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