結果

問題 No.2394 部分和乗総和
ユーザー かつっぱ競プロかつっぱ競プロ
提出日時 2023-07-28 21:29:01
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
WA  
実行時間 -
コード長 145 bytes
コンパイル時間 225 ms
コンパイル使用メモリ 12,288 KB
実行使用メモリ 22,840 KB
最終ジャッジ日時 2024-04-16 05:18:52
合計ジャッジ時間 5,442 ms
ジャッジサーバーID
(参考情報)
judge3 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 30 ms
10,368 KB
testcase_01 AC 34 ms
10,240 KB
testcase_02 AC 33 ms
10,368 KB
testcase_03 AC 35 ms
10,496 KB
testcase_04 WA -
testcase_05 WA -
testcase_06 AC 31 ms
10,496 KB
testcase_07 AC 31 ms
10,496 KB
testcase_08 WA -
testcase_09 WA -
testcase_10 AC 31 ms
10,496 KB
testcase_11 AC 30 ms
10,368 KB
testcase_12 AC 31 ms
10,496 KB
testcase_13 WA -
testcase_14 WA -
testcase_15 WA -
testcase_16 WA -
testcase_17 WA -
testcase_18 WA -
testcase_19 WA -
testcase_20 AC 260 ms
22,840 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

N, M, B = map(int, input().split())
A = list(map(int, input().split()))

ans = 1

for a in A:
    ans = ans * (1 + pow(M, a, B)) % M

print(ans)
0