#include <bits/stdc++.h>
using namespace std;
long long a[10000], n, m, x, ip, ans, r;
int main() {
  cin >> n >> x;
  for (int i = 1; i <= n; i++) cin >> a[i];
  sort(a + 1, a + n + 1);
  m = (1 + n) / 2;
  r = n % 2;
  if (a[m] == x) {
    cout << 0;
    return 0;
  }
  if (a[m] < x) {
    if (r == 0)
      r = 1;
    else
      r = 0;
    ip = n + 1;
    for (int i = m; i <= n; i++)
      if (a[i] >= x) {
        ip = i;
        break;
      }
    ip = ip - m;
    ans = ip * 2 - r;
  }
  if (a[m] > x) {
    ip = 0;
    for (int i = m; i >= 1; i--)
      if (a[i] <= x) {
        ip = i;
        break;
      }
    ip = m - ip;
    ans = ip * 2 - r;
  }
  cout << ans;
  return 0;
}
