/*************************************************************************
	> File Name: 2.cpp
	> Author: Knowledge_llz
	> Mail: 925538513@qq.com 
	> Blog: https://blog.csdn.net/Pig_cfbsl 
	> Created Time: 2020/10/24 21:01:12
 ************************************************************************/

#include<iostream>
#include<cstdio>
#include<cstdlib>
#include<cmath>
#include<cstring>
#include<algorithm>
#define For(i,a,b) for(register int i=(a);i<=(b);++i)
#define LL long long
using namespace std;
int read(){
	char x=getchar(); int u=0,fg=0;
	while(!isdigit(x)){ if(x=='-') fg=1; x=getchar(); }
	while(isdigit(x)){ u=(u<<3)+(u<<1)+(x^48); x=getchar(); }
	return fg?-u:u;
}
const int maxx=2e5+10,mod=998244353;
LL n,k,a[maxx][320],sum[320],ans[320],c[320][320];
void init(){
	For(i,0,300) c[0][i]=1;
	For(i,1,300) For(j,1,i)
		c[i][j]=(c[i-1][j-1]+c[i-1][j])%mod;
}
LL qpow(LL x,LL y){
	LL res=1;
	while(y){
		if(y&1) res=res*x%mod;
		x=x*x%mod;
		y>>=1;
	}
	return res;
}
int main()
{
#ifndef ONLINE_JUDGE
	freopen("input.in", "r", stdin);
	freopen("output.out", "w", stdout);
#endif
	init();
	LL inv=qpow(2,mod-2);
	n=read(); k=read();
	For(i,1,n){
		a[i][1]=read();
		For(j,2,k) a[i][j]=a[i][j-1]*a[i][1]%mod;
	}
	For(i,1,k) For(j,1,n) (sum[i]+=a[j][i])%=mod;
	For(i,1,k)
		For(j,1,k-i){
			ans[i+j]=(ans[i+j]+c[i+j][i]*sum[i]%mod*sum[j]%mod)%mod;
		}
	For(i,2,k){ 
		(ans[i]-=(qpow(2,i)-2)*sum[i]%mod)%=mod;
		ans[i]=ans[i]*inv%mod;
	}
	For(i,1,k){
		(ans[i]+=sum[i]*(n-1)%mod)%=mod;
		printf("%lld\n",(ans[i]+mod)%mod);
	}
	
	return 0;
}

#include <iostream>
#include <vector>
#include <map>
#include <set>
#include <queue>
#include <algorithm>
#include <string>
#include <cmath>
#include <cstdio>
#include <iomanip>
#include <fstream>
#include <cassert>
#include <cstring>
#include <unordered_set>
#include <unordered_map>
#include <numeric>
#include <ctime>
#include <bitset>
#include <complex>
#include <chrono>
#include <random>
#include <functional>

using namespace std;

const int N = 2e5 + 8;
const int K = 301;
const int MOD = 998244353;

int add(int a, int b) {
    if (a + b < MOD) {
        return a + b;
    }
    return a + b - MOD;
}

int sub(int a, int b) {
    if (a >= b) {
        return a - b;
    }
    return a - b + MOD;
}

int mul(int a, int b) {
    return 1LL * a * b % MOD;
}

int binpow(int a, int b) {
    int res = 1;
    while (b) {
        if (b & 1) res = mul(res, a);
        a = mul(a, a);
        b /= 2;
    }
    return res;
}

int divv(int a, int b) {
    return mul(a, binpow(b, MOD - 2));
}

int a[N];
int s[K];
int ans[K];
int C[K][K];

void init() {
    for (int i = 0; i < K; i++) {
        C[i][0] = 1;
        for (int j = 1; j <= i; j++) {
            C[i][j] = add(C[i - 1][j], C[i - 1][j - 1]);
        }
    }
}

signed main() {
    ios_base::sync_with_stdio(false);
    cin.tie(0);

    init();

    int n, k;
    cin >> n >> k;
    for (int i = 0; i < n; i++) {
        cin >> a[i];
    }
    for (int i = 0; i < n; i++) {
        int c = 1;
        for (int j = 0; j < K; j++) {
            s[j] = add(s[j], c);
            c = mul(c, a[i]);
        }
    }
    for (int i = 0; i < K; i++) {
        for (int j = 0; i + j < K; j++) {
            int S = mul(s[i], s[j]);
            S = sub(S, s[i + j]);
            S = divv(S, 2);
            ans[i + j] = add(ans[i + j], mul(C[i + j][j], S));
        }
    }
    for (int i = 1; i <= k; i++) {
        cout << ans[i] << '\n';
    }
}
