#include<bits/stdc++.h>

using namespace std;

using ll = long long;

const int N = (int)1e6 + 5, M = (int)5e5 + 5, mod = 998244353;
int n, m, fact[4 * M], inv_fact[4 * M], ans;

int add (int _a, int _b) {
    _a += _b;
    if (_a >= mod) _a -= mod;
    return _a;
}

int multi (int _a, int _b) { return (int)( (ll)_a * _b % mod); }

int bin_pow (int _a, int _n) {
    int ret = 1;
    for (; _n; _n >>= 1, _a = multi(_a, _a) ) if (_n & 1) ret = multi(ret, _a);
    return ret;
}

int C (int _k, int _n) {
    if (_k < 0 || _k > _n || _n < 0) return 0;
    return multi(fact[_n], multi(inv_fact[_k], inv_fact[_n - _k]) );
}

int candy_distribution (int _n, int _sum) { return C(_n - 1, _sum + _n - 1); }

int main () {
    ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);

    fact[0] = 1; for (int i = 1; i < 4 * M; ++i) fact[i] = multi(fact[i - 1], i);
    inv_fact[4 * M - 1] = bin_pow(fact[4 * M - 1], mod - 2);
    for (int i = 4 * M - 2; i >= 0; --i) inv_fact[i] = multi(inv_fact[i + 1], i + 1);

    cin >> n >> m;

    for (int n_odd = 0; n_odd <= m; ++n_odd) {
        int rem = 3 * m - n_odd;
        if (rem & 1) continue ;
        rem >>= 1;
        ans = add(ans, multi(C(n_odd, n), candy_distribution(n, rem) ) );
    }

    for (int exceed = 2 * m + 1; exceed <= 3 * m; ++exceed) {
        int rem = 3 * m - exceed;
        ans = add(ans, mod - multi(n, candy_distribution(n - 1, rem) ) );
    }

    cout << ans << '\n';

    return 0;
}
