#include <bits/stdc++.h>
using namespace std;
int n, x;
bool exist = false;
vector<int> num;
int solve(int add) {
  int ans = 0;
  vector<int> tmp = num;
  while (tmp[(tmp.size() + 1) / 2 - 1] != x && ans < 505) {
    tmp.push_back(add);
    sort(tmp.begin(), tmp.end());
    ++ans;
  }
  return ans;
}
int main() {
  cin >> n >> x;
  num.resize(n);
  for (int i = 0; i < n; ++i) {
    cin >> num[i];
    if (num[i] == x) exist = true;
  }
  if (!exist) {
    ++n;
    num.push_back(x);
  }
  sort(num.begin(), num.end());
  cout << (!exist) + min(solve(1), min(solve(1000 * 100), solve(x)));
  return 0;
}
