#include <bits/stdc++.h>
#pragma GCC optimize(2)
#pragma GCC optimize(3)
#pragma GCC optimize("Ofast")
#pragma GCC optimize("inline")
using namespace std;
const long long p = 998244353, g = 3, gv = 332748118, N = 1e6 + 5;
long long qpow(long long a, int b) {
  long long ret = 1;
  while (b) {
    if (b & 1) ret = ret * a % p;
    a = a * a % p;
    b >>= 1;
  }
  return ret;
}
long long inv(long long a) { return qpow(a, p - 2); }
int rev[N];
void getrev(int len) {
  for (int i = 0; i < len; i++) {
    rev[i] = rev[i >> 1] >> 1;
    if (i & 1) rev[i] |= (len >> 1);
  }
}
void ntt(vector<long long> &a, int len, int tp) {
  a.resize(len);
  for (int i = 0; i < len; i++)
    if (i < rev[i]) swap(a[i], a[rev[i]]);
  for (int i = 2; i <= len; i <<= 1) {
    long long wn = qpow(tp == 1 ? g : gv, (p - 1) / i);
    int stp = i >> 1;
    for (int j = 0; j < len; j += i) {
      long long w = 1;
      for (int k = j; k < j + stp; k++) {
        long long s1 = a[k], s2 = a[k + stp] * w % p;
        w = w * wn % p;
        a[k] = (s1 + s2) % p, a[k + stp] = (s1 + p - s2) % p;
      }
    }
  }
  if (tp == -1) {
    long long lv = inv(len);
    for (int i = 0; i < len; i++) a[i] = a[i] * lv % p;
  }
}
vector<long long> operator*(vector<long long> a, vector<long long> b) {
  int len = 1, n = a.size() + b.size() - 1;
  while (len < n) len <<= 1;
  getrev(len);
  ntt(a, len, 1), ntt(b, len, 1);
  for (int i = 0; i < len; i++) a[i] = a[i] * b[i] % p;
  ntt(a, len, -1);
  a.resize(n);
  return a;
}
vector<long long> operator+(vector<long long> a, vector<long long> b) {
  if (a.size() < b.size()) swap(a, b);
  for (int i = 0; i < b.size(); i++) a[i] = (a[i] + b[i]) % p;
  return a;
}
vector<long long> operator-(vector<long long> a) {
  for (int i = 0; i < a.size(); i++) a[i] = (p - a[i]) % p;
  return a;
}
vector<long long> operator-(vector<long long> a, vector<long long> b) {
  return a + (-b);
}
vector<long long> operator*(long long b, vector<long long> a) {
  for (int i = 0; i < a.size(); i++) a[i] = a[i] * b % p;
  return a;
}
vector<long long> operator/(vector<long long> a, long long b) {
  int v = inv(b);
  for (int i = 0; i < a.size(); i++) a[i] = a[i] * v % p;
  return a;
}
long long fac[N], finv[N], iv[N];
int main() {
  int n;
  long long m;
  scanf("%d%lld", &n, &m);
  n++;
  fac[0] = fac[1] = iv[1] = finv[0] = finv[1] = 1;
  for (int i = 2; i <= n; i++)
    fac[i] = fac[i - 1] * i % p, iv[i] = (p - p / i) * iv[p % i] % p,
    finv[i] = finv[i - 1] * iv[i] % p;
  vector<long long> a, b, c;
  a.resize(n), b.resize(n);
  for (int i = 0; i < n; i++) {
    int x;
    scanf("%d", &x);
    a[i] = x * 1ll * fac[i] % p, b[n - i - 1] = finv[i];
  }
  c = a * b;
  for (int i = 0; i < n; i++)
    a[i] = c[n + i - 1] * 1ll * qpow(iv[i + 1], m % (p - 1)) % p,
    b[n - i - 1] = i & 1 ? p - finv[i] : finv[i];
  c = a * b;
  for (int i = 0; i < n; i++) printf("%lld ", c[n + i - 1] * 1ll * finv[i] % p);
  printf("\n");
}
