#include <bits/stdc++.h>
using namespace std;
long long int numbers[1000000];
int main(void) {
  int n;
  scanf("%d", &n);
  int i = 1;
  while (i <= n) {
    scanf("%lld", &numbers[i]);
    i++;
  }
  sort(numbers + 1, numbers + n + 1);
  long long int temp1, temp2;
  int n1, n2;
  if (n % 2 != 0)
    printf("%lld\n", numbers[(n / 2) + 1]);
  else {
    temp1 = 0;
    i = 1;
    n1 = n / 2;
    while (i <= n) {
      temp1 = temp1 + abs(numbers[n1] - numbers[i]);
      i++;
    }
    temp2 = 0;
    i = 1;
    n2 = n / 2 + 1;
    while (i <= n) {
      temp2 = temp2 + abs(numbers[n2] - numbers[i]);
      i++;
    }
    if (temp1 > temp2)
      printf("%lld\n", numbers[n2]);
    else
      printf("%lld\n", numbers[n1]);
  }
  return 0;
}
