#include #include using namespace std; using namespace atcoder; using ll=long long; using ld=long double; ld pie=3.14159265359; ll inf=1001; ll mod=998244353; int main(){ ll n,k; cin >> n >> k; vector>dp(n+1,vector(k+1,0)); vectormemo(k+1,0); memo[0]=1; dp[n][0]=1; for (ll i = n-1; i >=0; i--) { for (ll j = 1; j <=k; j++) { dp[i][j]+=(memo[j-1]*inv_mod(n-i,mod))%mod; dp[i][j]%=mod; memo[j-1]+=dp[i][j-1]; memo[j-1]%=mod; } } ll ans=0; for (ll i = 0; i <=k; i++) { ans+=dp[0][i]; ans%=mod; } cout << ans << endl; }