結果

問題 No.2113 Distance Sequence 1.5
ユーザー 👑 rin204rin204
提出日時 2022-10-28 21:52:21
言語 PyPy3
(7.3.15)
結果
WA  
実行時間 -
コード長 167 bytes
コンパイル時間 304 ms
コンパイル使用メモリ 87,100 KB
実行使用メモリ 71,652 KB
最終ジャッジ日時 2023-09-20 04:46:38
合計ジャッジ時間 3,417 ms
ジャッジサーバーID
(参考情報)
judge15 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 77 ms
71,164 KB
testcase_01 AC 78 ms
71,432 KB
testcase_02 AC 77 ms
71,420 KB
testcase_03 AC 75 ms
71,284 KB
testcase_04 AC 75 ms
71,224 KB
testcase_05 AC 75 ms
71,164 KB
testcase_06 AC 74 ms
71,388 KB
testcase_07 WA -
testcase_08 AC 75 ms
71,280 KB
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 AC 72 ms
71,068 KB
testcase_15 WA -
testcase_16 AC 73 ms
70,980 KB
testcase_17 AC 74 ms
71,284 KB
testcase_18 AC 74 ms
71,116 KB
testcase_19 AC 75 ms
71,428 KB
testcase_20 WA -
testcase_21 AC 73 ms
71,112 KB
testcase_22 WA -
testcase_23 AC 75 ms
71,280 KB
testcase_24 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

MOD = 998244353

n, m, k = map(int, input().split())

ans = pow(k, 2 * n, MOD) - pow(k - 1, 2 * n, MOD)
ans *= m - k + 1
ans += pow(k - 1, 2 * n, MOD)
print(ans % MOD)
0