#include <bits/stdc++.h>
using namespace std;
const long long N = 1000;
const long long inf = 0x3f3f3f3f;
const double p = (1.0 + sqrt(5.0)) / 2.0;
inline long long r() {
  char ch = getchar();
  long long f1 = 0, f2 = 1;
  while (ch < '0' || ch > '9') {
    if (ch == '-') f2 = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    f1 = (f1 << 3) + (f1 << 1) + (ch ^ 48);
    ch = getchar();
  }
  return f1 * f2;
}
long long a, b, s[N + 10], S;
double dp[110][100010], sum[100010];
signed main() {
  scanf("%d%d", &a, &b);
  long long x;
  for (long long i = 1; i <= a; i++) {
    scanf("%d", &s[i]);
    S += s[i];
  }
  dp[0][0] = sum[0] = 1;
  for (long long i = 1; i <= a; i++) {
    for (long long j = i; j <= i * b; j++) {
      long long l = max(j - b, i - 1), r = min(j - 1, (i - 1) * b);
      dp[i][j] = 1.0 / (b - 1) * sum[r];
      if (l) dp[i][j] -= 1.0 / (b - 1) * sum[l - 1];
      if (l <= j - s[i] && j - s[i] <= r)
        dp[i][j] -= 1.0 / (b - 1) * dp[i - 1][j - s[i]];
    }
    sum[0] = 0;
    for (long long j = 1; j <= i * b; j++) sum[j] = sum[j - 1] + dp[i][j];
  }
  double ans = sum[S - 1];
  printf("%.16lf", ans * (b - 1) + 1);
  return 0;
}
