結果

問題 No.586 ダブルブッキング
ユーザー fV9TwBhUoa9S3eVfV9TwBhUoa9S3eV
提出日時 2019-09-25 11:43:37
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 24 ms / 2,000 ms
コード長 245 bytes
コンパイル時間 382 ms
コンパイル使用メモリ 11,764 KB
実行使用メモリ 10,052 KB
最終ジャッジ日時 2023-10-21 21:03:37
合計ジャッジ時間 1,096 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 24 ms
10,052 KB
testcase_01 AC 24 ms
10,052 KB
testcase_02 AC 23 ms
10,052 KB
testcase_03 AC 23 ms
10,052 KB
testcase_04 AC 23 ms
10,052 KB
testcase_05 AC 23 ms
10,052 KB
testcase_06 AC 23 ms
10,052 KB
testcase_07 AC 24 ms
10,052 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

# No.586 ダブルブッキング
p1, p2, n = [int(input()) for i in range(3)]
r = [int(input()) for i in range(n)]
rooms = []

lost = 0

for tmp in r:
    if tmp in rooms:
        lost += p1 + p2
    else:
        rooms.append(tmp)

print(lost)
0