結果
| 問題 |
No.988 N×Mマス計算(総和)
|
| コンテスト | |
| ユーザー |
nohakai3
|
| 提出日時 | 2022-07-24 17:50:45 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
AC
|
| 実行時間 | 312 ms / 2,000 ms |
| コード長 | 266 bytes |
| コンパイル時間 | 277 ms |
| コンパイル使用メモリ | 12,672 KB |
| 実行使用メモリ | 26,680 KB |
| 最終ジャッジ日時 | 2024-07-06 12:38:19 |
| 合計ジャッジ時間 | 3,953 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 19 |
ソースコード
n,m,k=map(int,input().split())
l1=list(map(str,input().split()))
l2=[]
for i in range(n):
s=int(input())
l2.append(s)
l4=l1[1:]
l3=[]
for x in l4:
l3.append(int(x))
if l1[0]=="+":
print((m*sum(l2)+n*sum(l3))%k)
else:
print((sum(l2)*sum(l3))%k)
nohakai3