中位数
                var n = parseInt(read_line())
                var arr = read_line().split(' ')
                arr = arr.map(e=>parseInt(e))
                arr.sort(up)
                function up (a,b){ // 排序
                    return a-b
                }
                var sum = 0
                if(n%2===0){ // 取中位数
                    sum = (arr[n/2] + arr[n/2-1])/2
                    print(sum)
                } else {
                    print(arr[(n-1)/2])
                }