結果

問題 No.2351 Butterfly in Summer
ユーザー miho-4miho-4
提出日時 2023-06-16 21:32:27
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 70 ms / 2,000 ms
コード長 100 bytes
コンパイル時間 769 ms
コンパイル使用メモリ 86,828 KB
実行使用メモリ 71,152 KB
最終ジャッジ日時 2023-09-06 18:47:22
合計ジャッジ時間 3,453 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 68 ms
70,756 KB
testcase_01 AC 69 ms
70,768 KB
testcase_02 AC 67 ms
70,984 KB
testcase_03 AC 68 ms
70,644 KB
testcase_04 AC 70 ms
71,096 KB
testcase_05 AC 69 ms
70,768 KB
testcase_06 AC 69 ms
71,148 KB
testcase_07 AC 70 ms
71,096 KB
testcase_08 AC 70 ms
70,992 KB
testcase_09 AC 70 ms
71,076 KB
testcase_10 AC 69 ms
70,980 KB
testcase_11 AC 70 ms
70,948 KB
testcase_12 AC 69 ms
70,640 KB
testcase_13 AC 70 ms
70,648 KB
testcase_14 AC 70 ms
70,756 KB
testcase_15 AC 69 ms
71,152 KB
testcase_16 AC 68 ms
71,112 KB
testcase_17 AC 69 ms
70,752 KB
testcase_18 AC 68 ms
71,136 KB
testcase_19 AC 70 ms
71,128 KB
testcase_20 AC 69 ms
70,648 KB
testcase_21 AC 67 ms
70,832 KB
testcase_22 AC 70 ms
70,884 KB
testcase_23 AC 69 ms
70,976 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

n,k=map(int,input().split())
mod=998244353

ans=n*k*(k-1)*pow(pow(k,n,mod),mod-2,mod)%mod
print(ans)
0