#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, i, x;
  vector<int> a;
  cin >> n >> x;
  bool f = false;
  for (i = 0; i < n; i++) {
    int q;
    cin >> q;
    if (q == x) f = true;
    a.push_back(q);
  }
  int ans = 0;
  if (!f) {
    n++;
    ans++;
    a.push_back(x);
  }
  sort(a.begin(), a.end());
  int place = (n + 1) / 2 - 1;
  while (a[place] != x) {
    if (a[place] > x)
      a.push_back(0);
    else
      a.push_back(100500);
    sort(a.begin(), a.end());
    ans++;
    n++;
    place = (n + 1) / 2 - 1;
  }
  cout << ans;
  return 0;
}
