#include <bits/stdc++.h>
using std::cin;
using std::cout;
int main() {
  int n, x;
  cin >> n >> x;
  std::vector<int> arr;
  for (int t = 0; t < n; ++t) {
    int elem;
    cin >> elem;
    arr.push_back(elem);
  }
  std::sort(arr.begin(), arr.end());
  int med = (n + 1) / 2 - 1;
  int answer = 0;
  while (arr.at(med) != x) {
    arr.push_back(x);
    ++n;
    ++answer;
    med = (n + 1) / 2 - 1;
    std::sort(arr.begin(), arr.end());
  }
  cout << answer;
  return 0;
}
