#include #include using namespace std; using ll = long long; using mint = atcoder::modint998244353; #define rep(i, n) for (int i = 0; i < (int)(n); i++) void solve() { ll x, k; cin >> x >> k; if (x == 0 || x == 100) { cout << "0\n"; return; } vector dp(30, vector(30, 0)); mint p = mint(x) * mint(100).inv(), q = mint(100 - x) * mint(100).inv(); dp[1][1] = 1; rep(ki, k * 2) { vector nex(30, vector(30, 0)); nex[0] = dp[0]; for (ll cd = 1; cd < 25; cd++) { for (ll md = cd; md < 25; md++) { nex[cd + 1][max(cd + 1, md)] += dp[cd][md] * p; nex[cd - 1][md] += dp[cd][md] * q; } } swap(dp, nex); } mint ans; rep(md, 25) ans += dp[1][md + 1] * md; cout << ans.val() << '\n'; } int main() { std::cin.tie(nullptr); std::ios_base::sync_with_stdio(false); int T = 1; for (int t = 0; t < T; t++) { solve(); } return 0; }