結果
| 問題 | No.586 ダブルブッキング |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2017-12-22 17:03:29 |
| 言語 | Python3 (3.14.3 + numpy 2.4.4 + scipy 1.17.1) |
| 結果 |
AC
|
| 実行時間 | 93 ms / 2,000 ms |
| コード長 | 284 bytes |
| 記録 | |
| コンパイル時間 | 386 ms |
| コンパイル使用メモリ | 20,828 KB |
| 実行使用メモリ | 15,360 KB |
| 最終ジャッジ日時 | 2026-05-27 01:08:09 |
| 合計ジャッジ時間 | 1,962 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge3_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 5 |
ソースコード
from collections import Counter
P1 = int(input())
P2 = int(input())
N = int(input())
R = [int(input()) for i in range(N)]
cnter = Counter(R)
loss = 0
one_loss = P1 + P2
for key in cnter.keys():
cnt = cnter.get(key)
if cnt > 1:
loss += one_loss * (cnt - 1)
print(loss)