#include <bits/stdc++.h>
typedef long long ll;
#define FOR(i,a,b) for(ll i=(a);i<(b);i++)
#define REP(i,a) FOR(i,0,a)
using namespace std;
ll N,M;
const ll MOD=998244353,MAX_M=5e5,MAX_N=1e6;
ll fact[3*MAX_M+MAX_N],ifact[3*MAX_M+MAX_N];
void sub(ll &a,ll b){
	a+=MOD-b;
	if(a>=MOD)a-=MOD;
}
ll comb(ll n,ll m){
	if(n<0 || m<0 || n<m)return 0;
	return fact[n]*ifact[m]%MOD*ifact[n-m]%MOD;
}
ll zyuhuku(ll n,ll m){
	return comb(n+m-1,n);
}
ll mpw(ll n,ll m){
	ll r=1;
	while(m){
		if(m&1){
			r*=n;
			r%=MOD;
		}
		n*=n;
		n%=MOD;
		m>>=1;
	}
	return r;
}
ll minv(ll n){
	return mpw(n,MOD-2);
}
int main(){
	ios::sync_with_stdio(false);
	cin.tie(0);
	cin>>N>>M;
	fact[0]=1;
	REP(i,3*M+N-1){
		fact[i+1]=fact[i]*(i+1)%MOD;
	}
	ifact[3*M+N-1]=minv(fact[3*M+N-1]);
	for(ll i=3*M+N-2;i>=0;i--){
		ifact[i]=ifact[i+1]*(i+1)%MOD;
	}
	ll ans=0;
	ans=zyuhuku(3*M,N);
	FOR(i,2*M+1,3*M+1){
		sub(ans,N*zyuhuku(3*M-i,N-1)%MOD);
	}
	REP(i,M){
		sub(ans,zyuhuku(i,N)*comb(N,3*M-2*i)%MOD);
	}
	cout<<ans<<endl;
}
### Prompt

Your challenge is to write a Cpp solution to the following problem:

We have a sequence of N integers: x=(x_0,x_1,\cdots,x_{N-1}). Initially, x_i=0 for each i (0 \leq i \leq N-1).

Snuke will perform the following operation exactly M times:

* Choose two distinct indices i, j (0 \leq i,j \leq N-1,\ i \neq j). Then, replace x_i with x_i+2 and x_j with x_j+1.



Find the number of different sequences that can result after M operations. Since it can be enormous, compute the count modulo 998244353.

Constraints

* 2 \leq N \leq 10^6
* 1 \leq M \leq 5 \times 10^5
* All values in input are integers.

Input

Input is given from Standard Input in the following format:


N M


Output

Print the number of different sequences that can result after M operations, modulo 998244353.

Examples

Input

2 2


Output

3


Input

3 2


Output

19


Input

10 10


Output

211428932


Input

100000 50000


Output

3463133

### Response

```cpp
#include <bits/stdc++.h>
typedef long long ll;
#define FOR(i,a,b) for(ll i=(a);i<(b);i++)
#define REP(i,a) FOR(i,0,a)
using namespace std;
ll N,M;
const ll MOD=998244353,MAX_M=5e5,MAX_N=1e6;
ll fact[3*MAX_M+MAX_N],ifact[3*MAX_M+MAX_N];
void sub(ll &a,ll b){
	a+=MOD-b;
	if(a>=MOD)a-=MOD;
}
ll comb(ll n,ll m){
	if(n<0 || m<0 || n<m)return 0;
	return fact[n]*ifact[m]%MOD*ifact[n-m]%MOD;
}
ll zyuhuku(ll n,ll m){
	return comb(n+m-1,n);
}
ll mpw(ll n,ll m){
	ll r=1;
	while(m){
		if(m&1){
			r*=n;
			r%=MOD;
		}
		n*=n;
		n%=MOD;
		m>>=1;
	}
	return r;
}
ll minv(ll n){
	return mpw(n,MOD-2);
}
int main(){
	ios::sync_with_stdio(false);
	cin.tie(0);
	cin>>N>>M;
	fact[0]=1;
	REP(i,3*M+N-1){
		fact[i+1]=fact[i]*(i+1)%MOD;
	}
	ifact[3*M+N-1]=minv(fact[3*M+N-1]);
	for(ll i=3*M+N-2;i>=0;i--){
		ifact[i]=ifact[i+1]*(i+1)%MOD;
	}
	ll ans=0;
	ans=zyuhuku(3*M,N);
	FOR(i,2*M+1,3*M+1){
		sub(ans,N*zyuhuku(3*M-i,N-1)%MOD);
	}
	REP(i,M){
		sub(ans,zyuhuku(i,N)*comb(N,3*M-2*i)%MOD);
	}
	cout<<ans<<endl;
}
```