結果

問題 No.1836 Max Matrix
ユーザー aaaaaaaaaa2230aaaaaaaaaa2230
提出日時 2022-02-13 11:17:49
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 285 ms / 2,000 ms
コード長 218 bytes
コンパイル時間 296 ms
コンパイル使用メモリ 86,868 KB
実行使用メモリ 76,112 KB
最終ジャッジ日時 2023-09-11 15:21:42
合計ジャッジ時間 3,881 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 73 ms
71,280 KB
testcase_01 AC 75 ms
71,420 KB
testcase_02 AC 226 ms
75,976 KB
testcase_03 AC 232 ms
75,928 KB
testcase_04 AC 159 ms
75,844 KB
testcase_05 AC 206 ms
76,028 KB
testcase_06 AC 171 ms
76,112 KB
testcase_07 AC 228 ms
75,924 KB
testcase_08 AC 124 ms
76,056 KB
testcase_09 AC 232 ms
76,100 KB
testcase_10 AC 174 ms
75,964 KB
testcase_11 AC 76 ms
71,304 KB
testcase_12 AC 285 ms
76,060 KB
testcase_13 AC 141 ms
76,012 KB
testcase_14 AC 152 ms
76,020 KB
testcase_15 AC 84 ms
75,852 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

h,w,m = map(int,input().split())
mod = 998244353
ans = 1
bh,bw = 1,1
for i in range(1,m)[::-1]:
    dif = m-i+1
    nh,nw = pow(dif,h,mod),pow(dif,w,mod)
    ans = (ans+(nh-bh)*(nw-bw))%mod
    bh,bw = nh,nw
print(ans)
0