#include <bits/stdc++.h>
inline int read() {
  int data = 0, w = 1;
  char ch = getchar();
  while (ch != '-' && !std::isdigit(ch)) ch = std::getchar();
  if (ch == '-') w = -1, ch = std::getchar();
  while (std::isdigit(ch)) data = data * 10 + (ch ^ 48), ch = std::getchar();
  return data * w;
}
constexpr int N(1 << 16 | 10), M(17), Mod(998244353);
inline int upd(const int &x) { return x + (x >> 31 & Mod); }
int fastpow(int x, int y) {
  int ans = 1;
  for (; y; y >>= 1, x = 1ll * x * x % Mod)
    if (y & 1) ans = 1ll * ans * x % Mod;
  return ans;
}
std::map<std::vector<int>, int> map;
int n, K, C, lim, sum, cur, fac[M], inv[M], rev[M];
int p[M * M][N], cnt[N], tot[M * M], vis[N];
int f[N][M], g[N][M], h[N];
void Ln(int *f) {
  static int g[M];
  std::memset(g, 0, (K + 1) << 2);
  for (int i = 1; i <= K; g[i] = (1ll * i * f[i] - g[i]) % Mod, i++)
    for (int j = 1; j < i; j++) g[i] = (g[i] + 1ll * g[j] * f[i - j]) % Mod;
  for (int i = 0; i <= K; i++) f[i] = upd(1ll * rev[i] * g[i] % Mod);
}
void Exp(int *f) {
  static int g[M];
  std::memset(g, 0, (K + 1) << 2), g[0] = 1;
  for (int i = 1; i <= K; i++) f[i] = 1ll * i * f[i] % Mod;
  for (int i = 1; i <= K; g[i] = 1ll * rev[i] * g[i] % Mod, i++)
    for (int j = 1; j <= i; j++) g[i] = (g[i] + 1ll * f[j] * g[i - j]) % Mod;
  std::memcpy(f, g, (K + 1) << 2);
}
int main() {
  n = 16, fac[0] = 1;
  for (int i = 1; i <= n; i++) fac[i] = 1ll * fac[i - 1] * i % Mod;
  inv[n] = fastpow(fac[n], Mod - 2);
  for (int i = n; i; i--) inv[i - 1] = 1ll * inv[i] * i % Mod;
  for (int i = 1; i <= n; i++) rev[i] = 1ll * fac[i - 1] * inv[i] % Mod;
  n = read(), K = read(), C = read(), lim = 1 << C;
  for (int i = 1; i < lim; i++) cnt[i] = cnt[i >> 1] + (i & 1);
  for (int i = 1, x; i <= n; i++) {
    sum ^= (x = read());
    std::vector<int> v;
    v.reserve(K);
    for (int j = 1; j <= K; j++) v.push_back(x ^ (x - j));
    ++map[v];
  }
  for (auto i : map) {
    auto v = i.first;
    tot[++cur] = i.second;
    for (int S = 0; S < lim; S++)
      for (int j = 0; j < K; j++)
        if (cnt[v[j] & S] & 1) p[cur][S] |= (1 << j);
    for (int S = 0; S < lim; S++) vis[p[cur][S]] = 1;
  }
  for (int i = 0; i < (1 << K); i++)
    if (vis[i]) {
      f[i][0] = 1;
      for (int j = 0; j < K; j++)
        if (i >> j & 1)
          f[i][j + 1] = upd(-inv[j + 1]);
        else
          f[i][j + 1] = inv[j + 1];
      Ln(f[i]);
    }
  for (int i = 1; i <= cur; i++)
    for (int S = 0, c = tot[i]; S < lim; S++)
      for (int j = 0, x = p[i][S]; j <= K; j++)
        g[S][j] = (g[S][j] + 1ll * f[x][j] * c) % Mod;
  for (int S = 0; S < lim; S++) Exp(g[S]), h[S] = 1ll * g[S][K] * fac[K] % Mod;
  for (int i = 1; i < lim; i <<= 1)
    for (int j = 0; j < lim; j += (i << 1))
      for (int k = 0; k < i; k++) {
        int x = h[j + k], y = h[i + j + k];
        h[j + k] = upd(x + y - Mod), h[i + j + k] = upd(x - y);
      }
  int coef = 1ll * fastpow(lim, Mod - 2) * fastpow(n, Mod - 1 - K) % Mod;
  for (int i = 0; i < lim; i++) printf("%lld ", 1ll * coef * h[i ^ sum] % Mod);
  return 0;
}
