#include <bits/stdc++.h>
using namespace std;
long long n, m, ans;
string str;
long long solve() {
  long long n, x;
  vector<long long> v;
  cin >> n >> x;
  v.push_back(0);
  for (long long i = 1; i <= n; ++i) {
    long long a;
    cin >> a;
    v.push_back(a);
  }
  sort(v.begin(), v.end());
  while (v[((long long)((v).size())) / 2] != x) {
    v.push_back(x);
    sort(v.begin(), v.end());
  }
  cout << (long long)((v).size()) - 1 - n;
  return 0;
}
signed main() {
  ios::sync_with_stdio(0);
  long long t = 1;
  while (t--) solve();
  return 0;
}
