#include <bits/stdc++.h>
using namespace std;
const int MAXN = 100 + 10, MAXM = 1000 + 10;
int n, m, rnk, x[MAXN];
double sum[MAXN * MAXM], dp[MAXN][MAXN * MAXM], res;
int main() {
  cin >> n >> m;
  for (int i = 1; i <= n; cin >> x[i], rnk += x[i++])
    ;
  dp[0][0] = 1.0;
  for (int i = 1; i <= n; sum[0] = 0, ++i) {
    for (int j = 0; j <= i * m; ++j) sum[j + 1] = sum[j] + dp[i - 1][j];
    for (int j = i; j <= i * m; ++j) {
      dp[i][j] = sum[j] - sum[max(j - m, 0)];
      if (j >= x[i]) dp[i][j] -= dp[i - 1][j - x[i]];
      dp[i][j] /= (m - 1);
    }
  }
  for (int i = 1; i < rnk; res += dp[n][i++])
    ;
  cout << fixed << setprecision(10) << res * (m - 1) + 1 << endl;
  return 0;
}
