#include <bits/stdc++.h>
using namespace std;
const int N = 105;
const int M = 1005;
int n, m;
double f[2][N * M], pre[N * M];
int main() {
  scanf("%d%d", &n, &m);
  for (int i = 0; i <= n * m; i++) {
    f[0][i] = f[1][i] = 0;
    pre[i] = 1;
  }
  f[0][0] = 1;
  int x, cur = 1;
  int sum = 0;
  for (int i = 1; i <= n; i++) {
    scanf("%d", &x);
    sum += x;
    f[cur][0] = 0;
    for (int j = 1; j <= n * m; j++) {
      f[cur][j] = 0;
      if (j - m - 1 >= 0) {
        f[cur][j] += pre[j - 1] - pre[j - m - 1];
        f[cur][j] -= f[cur ^ 1][j - x];
      } else {
        if (j - x < 0) {
          f[cur][j] += pre[j - 1];
        } else {
          f[cur][j] += pre[j - 1];
          f[cur][j] -= f[cur ^ 1][j - x];
        }
      }
      f[cur][j] /= (m - 1);
    }
    pre[0] = 0;
    for (int j = 1; j <= n * m; j++) {
      pre[j] = 0;
      pre[j] += pre[j - 1] + f[cur][j];
    }
    cur ^= 1;
  }
  double ans = 0;
  if (m == 1) {
    printf("%.16lf\n", ans = 1);
    return 0;
  }
  for (int i = 0; i <= sum - 1; i++) {
    ans += f[cur ^ 1][i];
  }
  printf("%.16lf\n", ans * (m - 1) + 1);
  return 0;
}
