#include<iostream>
#include<cstring>
#include<cstdio>
#include<cmath>
#include<queue>
#include<algorithm>
#include<vector>
using namespace std;
const int MAX = 1e5 + 5;
struct str{
	int a,s;
}q[MAX];

int cmd(str x,str y){
	return x.a < y.a;
}

int main(){
	int n;
	scanf("%d",&n);
	for(int i = 1;i <= n; ++i){
		scanf("%d",&q[i].a);
	}
	int mid = n / 2 + 1;
	q[1].s = 1;
	for(int i = 2;i <= mid; ++i){
		q[i].s = q[i - 1].s + 2;
	}
	if(n % 2 == 0) q[mid].s--,q[mid + 1].s = q[mid].s - 2;
	else q[mid + 1].s = q[mid].s - 1;
	for(int i = mid + 2;i <= n; ++i){
		q[i].s = q[i - 1].s - 2;
	}
	sort(q + 1,q + n + 1,cmd);
	n = n * (n - 1) / 2 + n;
	mid = n / 2 + 1;
	int ans = 0,f;
	for(int i = 1;; ++i){
		ans += q[i].s;
		if(ans >= mid){
			f = i;
			break;
		}
	}
	printf("%d",q[f].a);
	return 0;
}