#include <bits/stdc++.h>
using namespace std;
int main() {
  double n, k, sum = 0, x, ans = 0;
  cin >> n >> k;
  for (int i = 1; i <= n; i++) {
    cin >> x;
    sum += x;
  }
  while (round(sum / n) != k) {
    ans++;
    n++;
    sum += k;
  }
  cout << ans << endl;
  return 0;
}
