#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  int i, j, n, m, l, t1;
  double mark, k, sum = 0, t2, t3;
  cin >> n >> k;
  for (i = 0; i < n; i++) {
    cin >> mark;
    sum += mark;
  }
  m = n;
  while (sum / n != k) {
    t1 = sum / n;
    t2 = sum / n;
    if (t2 - t1 >= 0.5) t3 = ceil(t2);
    if (t3 == k) {
      break;
    }
    sum += k;
    n++;
  }
  cout << n - m << endl;
  return 0;
}
