#include <bits/stdc++.h>
using namespace std;
int n, k, arr[101], sum, ans = 0;
double prom;
int main() {
  cin >> n >> k;
  for (int i = 0; i < n; i++) {
    cin >> arr[i];
    sum += arr[i];
  }
  while (1) {
    prom = (double)sum / (double)n;
    if (prom + 0.5 < k) {
      n++;
      sum += k;
      ans++;
    } else
      break;
  }
  cout << ans << '\n';
  return 0;
}
