結果

問題 No.988 N×Mマス計算(総和)
ユーザー chinchillachinchilla
提出日時 2020-02-14 22:04:06
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 80 ms / 2,000 ms
コード長 184 bytes
コンパイル時間 101 ms
コンパイル使用メモリ 10,660 KB
実行使用メモリ 23,236 KB
最終ジャッジ日時 2023-09-20 11:56:20
合計ジャッジ時間 1,933 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 15 ms
7,764 KB
testcase_01 AC 16 ms
7,848 KB
testcase_02 AC 16 ms
7,848 KB
testcase_03 AC 16 ms
7,880 KB
testcase_04 AC 15 ms
7,868 KB
testcase_05 AC 16 ms
7,760 KB
testcase_06 AC 15 ms
7,756 KB
testcase_07 AC 15 ms
7,764 KB
testcase_08 AC 16 ms
7,776 KB
testcase_09 AC 16 ms
7,844 KB
testcase_10 AC 34 ms
11,684 KB
testcase_11 AC 47 ms
18,308 KB
testcase_12 AC 66 ms
20,880 KB
testcase_13 AC 38 ms
14,720 KB
testcase_14 AC 37 ms
14,428 KB
testcase_15 AC 34 ms
10,528 KB
testcase_16 AC 56 ms
17,200 KB
testcase_17 AC 65 ms
19,776 KB
testcase_18 AC 44 ms
17,016 KB
testcase_19 AC 63 ms
19,784 KB
testcase_20 AC 80 ms
23,236 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
n, m, k = map(int, input().split())
op, *B = input().split()
A = list(map(int, sys.stdin))
B = list(map(int, B))
print({"+":(sum(A)*m + n*sum(B)), "*":sum(A)*sum(B)}[op]%k)
0