問題一覧 > 通常問題

No.2876 Infection

レベル : / AI推定難易度 : 1800 / 実行時間制限 : 1ケース 2.000秒 / メモリ制限 : 512 MB / 標準ジャッジ問題
タグ : (AC するまで非表示) / 解いたユーザー数 25
作問者 : 寝癖 / テスター : yuusaan 👑 seekworser
お気に入りにしたユーザー ProblemId : 11064 / 自分の提出
問題文最終更新日: 2024-09-06 21:50:51
This statement was translated by AI (claude-opus-5-5, effort medium) and may contain errors or differ in nuance from the original. The original statement takes precedence. Back to the original
yukicoder contest 444 (順位表) の他の問題:

Problem Statement

Neguse-kun attended a party with a total of $N$ participants.

The next day, it turned out that one of the attendees had been infected with a contagious virus at the start of the party.

Fortunately, no one else was infected at the start of the party, but

since this virus has the property of infecting other people with probability $x\%$, each attendee may have been infected, directly or indirectly,

by the end of the party. Infections are assumed to occur independently.

Find the expected number of people among the $N$ attendees who were infected with the virus at the end of the party, $\rm mod\ 998244353$.

More rigorous problem setting

More specifically, the following event takes place.

If there exists a person who is infected with the virus and has never yet performed the action below, choose one such person and perform the action below.

  • From the chosen person, infect each person who is not yet infected with the virus, independently with probability $x \%$.

It can be shown that the expected number of people infected at the end of the party does not depend on the order in which people are chosen in the above operation.

Input

$N$ $x$
  • $1\le N\le 2500$
  • $0\le x\le100$
  • All inputs are integers.

Output

Output the expected number of infected people, $\rm mod\ 998244353$, on one line.

Sample

Sample 1
Input
2 20
Output
598946613

With probability $20\%$ there are $2$ infected people, and with probability $80\%$ there is $1$ infected person, so the expected number of infected people is $\frac{1}{5}\times2+\frac{4}{5}\times1=\frac{6}{5}$.

Sample 2
Input
3 90
Output
644865855
Sample 3
Input
7 0
Output
1

提出するには、Twitter 、GitHub、 Googleもしくは右上の雲マークをクリックしてアカウントを作成してください。