// i_love_aisukiuwu #include #include using namespace std; #define ll long long #define all(a) (a).begin(), (a).end() #define vi vector #define pi pair #define fi first #define se second #define gcd __gcd #define mset(a, v) memset(a, v, sizeof(a)) #define endl '\n' const int N = 1e6 + 5, LOG = 27, MOD = 998244353; const ll INF = 1e18; void process(); signed main() { cin.tie(0); cout.tie(0); ios_base::sync_with_stdio(false); process(); cerr << endl << "Time elapsed: " << 1.0 * clock() / CLOCKS_PER_SEC << " s.\n"; } ll fact[N], inv[N]; ll bp(ll n, ll k) { ll res = 1; while (k > 0) { if (k & 1) res = res * n % MOD; n = n * n % MOD; k >>= 1; } return res; } void pre() { fact[0] = 1; for (ll i = 1; i < N; ++i) fact[i] = (fact[i - 1] * i) % MOD; inv[N - 1] = bp(fact[N - 1], MOD - 2); for (ll i = N - 2; i >= 0; --i) inv[i] = (inv[i + 1] * (i + 1)) % MOD; } ll n, m; void process() { auto C = [&](ll n, ll k) -> ll { if (n < 0 || k < 0 || n < k) return 0; return fact[n] * inv[k] % MOD * inv[n - k] % MOD; }; pre(); cin >> n >> m; ll res = 0; for (ll i = 1; i <= m; ++i) res = (res + C(2 * i - 2, n - 1)) % MOD; cout << res << endl; }