#include <bits/stdc++.h>
using namespace std;
int n, m, a[105], Sum;
double DP[105][100005], S[105][100005], res;
int main() {
  cin >> n >> m;
  if (m == 1) {
    cout << 1;
    return 0;
  }
  DP[0][0] = 1;
  for (int i = 0; i <= n * m; i++) S[0][i] = 1;
  for (int i = 1; i <= n; i++) {
    cin >> a[i];
    Sum += a[i];
    for (int j = 1; j <= m * n; j++) {
      DP[i][j] = S[i - 1][j - 1];
      if (j > m) DP[i][j] -= S[i - 1][j - m - 1];
      if (j >= a[i]) DP[i][j] -= DP[i - 1][j - a[i]];
      DP[i][j] *= 1.0 / (m - 1);
      S[i][j] = S[i][j - 1] + DP[i][j];
    }
  }
  res = S[n][Sum - 1] * (m - 1) + 1;
  printf("%0.9f", res);
}
