#include <bits/stdc++.h>
using namespace std;

typedef long long ll;
typedef vector<int> VI;
typedef vector<VI> VVI;
typedef vector<long long> VL;
typedef vector<vector<long long>> VVL;
typedef pair<int,int> P;
typedef tuple<int,int,int> tpl;

#define ALL(a)  (a).begin(),(a).end()
#define SORT(c) sort((c).begin(),(c).end())
#define REVERSE(c) reverse((c).begin(),(c).end())
#define EXIST(m,v) (m).find((v)) != (m).end()
#define LB(a,x) lower_bound((a).begin(), (a).end(), x) - (a).begin()
#define UB(a,x) upper_bound((a).begin(), (a).end(), x) - (a).begin()

#define FOR(i,a,b) for(int i=(a);i<(b);++i)
#define REP(i,n)  FOR(i,0,n)
#define RFOR(i,a,b) for(int i=(a)-1;i>=(b);--i)
#define RREP(i,n) RFOR(i,n,0)

#define en "\n"

constexpr double EPS = 1e-9;
constexpr double PI  = 3.1415926535897932;
constexpr int INF = 2147483647;
constexpr long long LINF = 1LL<<60;
constexpr long long MOD = 998244353;

template<class T> inline bool chmax(T& a, T b) { if (a < b) { a = b; return true; } return false; }
template<class T> inline bool chmin(T& a, T b) { if (a > b) { a = b; return true; } return false; }

void Main(){
    ll A,B,C; cin >> A >> B >> C;
    ll a = A*(A+1)/2 % MOD;
    ll b = B*(B+1)/2 % MOD;
    ll c = C*(C+1)/2 % MOD;
    ll ans = a*b%MOD;
    ans = ans*c%MOD;
    cout << ans << en;
    return;
}

int main(void){
    cin.tie(0);cout.tie(0);ios_base::sync_with_stdio(0);cout<<fixed<<setprecision(15);
    int t=1; //cin>>t;
    REP(_,t) Main();
    return 0;
}
#include <bits/stdc++.h>
using namespace std;
#define fi first
#define se second
#define Mp make_pair
#define pb push_back

using ll = long long;
using db = double;
using pii = pair<int, int>;
using vi = vector<int>;
mt19937 mrand(time(0));
ll get(ll r) { return ((ll)mrand() * mrand() % r + r) % r; }
ll get(ll l, ll r) { return get(r - l + 1) + l; }

ll n, K, P, f[110][110*110*110], up;
signed main() {
    scanf("%lld %lld %lld", &n, &K, &P), up = K * n * (n - 1) / 2, f[0][0] = 1;
    for(int i = 1; i < n; i++) {
        for(int j = 0; j <= up; j++) {
            f[i][j] = f[i - 1][j];
            if(j >= i) (f[i][j] += f[i][j - i]) %= P;
        }
        for(int j = up; j >= (K + 1) * i; j--)
            (f[i][j] += P - f[i][j - (K + 1) * i]) %= P;
    }
    for(int i = 1; i <= n; i++) {
        ll nw = 0;
        for(int j = 0; j <= up; j++)
            (nw += f[i - 1][j] * f[n - i][j]) %= P;
        printf("%lld\n", (nw * (K + 1) % P - 1 + P) % P);
    }
    fprintf(stderr, "time=%.4f\n", (db)clock()/CLOCKS_PER_SEC);
    return 0;
}