結果
問題 | No.156 キャンディー・ボックス |
ユーザー |
|
提出日時 | 2018-02-05 22:32:04 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
TLE
|
実行時間 | - |
コード長 | 297 bytes |
コンパイル時間 | 85 ms |
コンパイル使用メモリ | 12,416 KB |
実行使用メモリ | 16,256 KB |
最終ジャッジ日時 | 2024-07-08 07:24:51 |
合計ジャッジ時間 | 10,284 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 28 TLE * 1 -- * 1 |
ソースコード
# coding: utf-8 from collections import Counter import math n,m = map(int, input().split(" ")) candys = list(map(int,input().split(" "))) while m != 0: min_ = candys.pop(candys.index(min(candys))) min_ -= 1 if min_ != 0: candys.append(min_) m -= 1 print(n - len(candys))