#include <bits/stdc++.h>
using namespace std;
int n, m, c[105], s;
double dp[105][100005], sum[100005];
signed main() {
  cin >> n >> m;
  double p = 1.0 / (m - 1);
  for (int i = 1; i <= n; i++) {
    cin >> c[i];
    s += c[i];
  }
  dp[0][0] = sum[0] = 1;
  for (int i = 1; i <= n; i++) {
    int ls = min(s - 1, i * m);
    for (int j = i; j <= ls; j++) {
      int l = max(i - 1, j - m), r = min(i * m - m, j - 1);
      dp[i][j] = sum[r] * p;
      if (l) dp[i][j] -= sum[l - 1] * p;
      if (l <= j - c[i] && j - c[i] <= r) dp[i][j] -= p * dp[i - 1][j - c[i]];
    }
    sum[i - 1] = 0;
    for (int j = i; j <= ls; j++) sum[j] = sum[j - 1] + dp[i][j];
  }
  printf("%.10lf", (m - 1) * sum[s - 1] + 1);
}
