#include<bits/stdc++.h>
using namespace std;
#define M 998244353
#define N 200000
typedef long long int LL;
LL fact[301],invfact[301],sum[301],sum2[301];
LL ap[N][301],p2[301];
LL mult(LL a, LL b){
    return a*b%M;
}
LL add(LL a, LL b){
    return (a+b+M)%M;
}
LL c(LL n, LL k){
    return mult(fact[n],mult(invfact[k],invfact[n-k]));
}
LL p(LL b, LL x){
    if(x==0) return 1LL;
    LL sub=p(b,x/2);
    sub=mult(sub,sub);
    if(x&1) sub=mult(sub,b);
    return sub;
}
int main(){
#ifndef ONLINE_JUDGE
    freopen("input.txt","r",stdin);
    freopen("output.txt","w",stdout);
#endif
    int n,k;
    cin>>n>>k;
    int a[n];
    for(int i=0;i<n;i++){
        scanf("%d",a+i);
    }
    for(int i=0;i<n;i++){
        ap[i][0]=1;
    }
    for(int i=0;i<n;i++){
        for(int j=1;j<=k;j++){
            ap[i][j]=mult(ap[i][j-1],a[i]);
        } 
    } 
    fact[0]=invfact[0]=1;
    for(int i=1;i<301;i++){
        fact[i]=mult(fact[i-1],i),invfact[i]=p(fact[i],M-2);
    } 
    p2[0]=1;
    for(int i=1;i<301;i++){
        p2[i]=mult(2,p2[i-1]);
    } 
    for(int i=0;i<n;i++){
        for(int j=0;j<=k;j++){
            sum[j]=add(sum[j],ap[i][j]);
        } 
    } 
    int tinv=p(2,M-2);
    for(int X=1;X<=k;X++){
        int ans=0;
        for(int x=0;x<=X;x++){
            ans=add(ans,mult(c(X,x),mult(sum[X-x],sum[x])));
        }
        ans=add(ans,-mult(p2[X],sum[X]));
        ans=mult(ans,tinv);
        cout<<ans<<"\n";
    }
}


    #include <bits/stdc++.h>
    using namespace std;
    #include <math.h>
    #include <iomanip>
    #include <cstdint>
    #include <string>
    #include <sstream>
    template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return 1; } return 0; }
    template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return 1; } return 0; }
    #define rep(i,n) for (int i = 0; i < (n); ++i)
    typedef long long ll;
    using P=pair<ll,ll>;
    const int INF=1001001001;
    const int mod=998244353;
    
    struct mint {
      ll x; 
      mint(ll x=0):x((x%mod+mod)%mod){}
      mint operator-() const { return mint(-x);}
      mint& operator+=(const mint a) {
        if ((x += a.x) >= mod) x -= mod;
        return *this;
      }
      mint& operator-=(const mint a) {
        if ((x += mod-a.x) >= mod) x -= mod;
        return *this;
      }
      mint& operator*=(const mint a) { (x *= a.x) %= mod; return *this;}
      mint operator+(const mint a) const { return mint(*this) += a;}
      mint operator-(const mint a) const { return mint(*this) -= a;}
      mint operator*(const mint a) const { return mint(*this) *= a;}
      mint pow(ll t) const {
        if (!t) return 1;
        mint a = pow(t>>1);
        a *= a;
        if (t&1) a *= *this;
        return a;
      }
       
      mint inv() const { return pow(mod-2);}
      mint& operator/=(const mint a) { return *this *= a.inv();}
      mint operator/(const mint a) const { return mint(*this) /= a;}
     };
      istream& operator>>(istream& is, const mint& a) { return is >> a.x;}
      ostream& operator<<(ostream& os, const mint& a) { return os << a.x;}
      struct combination {
      vector<mint> fact, ifact;
      combination(int n):fact(n+1),ifact(n+1) {
        assert(n < mod);
        fact[0] = 1;
        for (int i = 1; i <= n; ++i) fact[i] = fact[i-1]*i;
        ifact[n] = fact[n].inv();
        for (int i = n; i >= 1; --i) ifact[i-1] = ifact[i]*i;
      }
      mint operator()(int n, int k) {
        if (k < 0 || k > n) return 0;
        return fact[n]*ifact[k]*ifact[n-k];
      }
     } c(2000005);

    int main() {
      int N,K;
      cin>>N>>K;
      vector<ll>A(N);
      rep(i,N){cin>>A[i];}
      vector<mint>sum(K+1);//sum[k]=A[0]^k+A[1]^k+A[2]^k+...
      rep(i,N){
        mint now=1;
        rep(j,K+1){
          sum[j]+=now;
          now*=A[i];
        }
      }
      for(int i=1;i<=K;i++){
        mint ans=0;
        for(int j=0;j<=i;j++){
          ans+=c(i,j)*sum[j]*sum[i-j];
          ans-=sum[i]*c(i,j);
        }
        ans/=2;
        cout<<ans<<endl;
      }
      return 0;
    }