#include <bits/stdc++.h>
using namespace std;
const double PI = acos(-1);
inline int read() {
  int x = 0, flag = 1;
  char c = getchar();
  while (c < '0' || c > '9') {
    if (c == '-') flag = 0;
    c = getchar();
  }
  while (c >= '0' && c <= '9') {
    x = (x << 1) + (x << 3) + c - 48;
    c = getchar();
  }
  return flag ? x : -x;
}
struct Complex {
  double x, y;
  Complex(double x_ = 0, double y_ = 0) : x(x_), y(y_) {}
  Complex operator+(const Complex X) { return Complex(x + X.x, y + X.y); }
  Complex operator-(const Complex X) { return Complex(x - X.x, y - X.y); }
  Complex operator*(const Complex X) {
    return Complex(x * X.x - y * X.y, x * X.y + y * X.x);
  }
} a[((1 << 21) + 3)];
int n, X, m = 0, op = 0, rk[((1 << 21) + 3)];
long long G[((1 << 21) + 3)];
void FFT() {
  for (int i = 0; i < n; i++)
    if (i < rk[i]) swap(a[i], a[rk[i]]);
  for (int p = 2; p <= n; p <<= 1) {
    int len = p >> 1;
    Complex w(cos(2 * PI / p), op * sin(2 * PI / p));
    for (int k = 0; k < n; k += p) {
      Complex now(1.0, 0.0);
      for (int l = k; l < k + len; l++) {
        Complex t = now * a[l + len];
        a[l + len] = a[l] - t;
        a[l] = a[l] + t;
        now = now * w;
      }
    }
  }
}
int main() {
  n = read(), X = read();
  a[0] = 1;
  int n_ = n;
  long long ret = 0;
  for (int i = 1; i <= n; i++) {
    int x = read();
    if (x < X)
      a[++m].x = 1;
    else
      a[m].x++;
  }
  for (int i = 0; i <= m; i++)
    a[m - i].y = a[i].x, ret += (long long)a[i].x * (a[i].x - 1) / 2;
  for (n = 1; n <= (m << 1); n <<= 1)
    ;
  for (int i = 0; i < n; i++)
    rk[i] = (rk[i >> 1] >> 1) | ((i & 1) ? n >> 1 : 0);
  op = 1, FFT();
  for (int i = 0; i < n; i++) a[i] = a[i] * a[i];
  op = -1, FFT();
  for (int i = 0; i <= m; i++) G[i] = (long long)(a[i].y / n / 2 + 0.5);
  reverse(G, G + 1 + m), G[0] = ret;
  for (int i = 0; i <= n_; i++) printf("%lld ", G[i]);
}
