#include<iostream>
#include<cstring>
#include<cstdio>
#include<cmath>
#include<queue>
#include<algorithm>
#include<vector>
using namespace std;
const int MAX = 1e5 + 5;
int a[MAX],b[MAX];
priority_queue<pair<int,int> > q;
int main(){
	int n;
	scanf("%d",&n);
	for(int i = 1;i <= n; ++i){
		scanf("%d",&a[i]);
	}
	long long mid = n / 2 + 1;
	b[1] = 1;
	for(int i = 2;i <= mid; ++i){
		b[i] = b[i - 1] + 2;
	}
	if(n % 2 == 0) b[mid]--,b[mid + 1] = b[mid] - 2;
	else b[mid + 1] = b[mid] - 1;
	for(int i = mid + 2;i <= n; ++i){
		b[i] = b[i - 1] - 2;
	}
	for(int i = 1;i <= n; ++i){
		q.push(make_pair(a[i],b[i]));
	}
	long long e = n * (n - 1) / 2 + n;
	long long r = e / 2 + 1;
	long long ans = 0,f;
	int x,y;
	for(int i = 1;; ++i){
		x = q.top().second;
		y = q.top().first;
		e -= x;
		q.pop();
		if(e <= r) break;
		
	}
	printf("%d",y);
	return 0;
}