結果
| 問題 |
No.78 クジ付きアイスバー
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2017-04-03 15:21:19 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 342 bytes |
| コンパイル時間 | 140 ms |
| コンパイル使用メモリ | 12,544 KB |
| 実行使用メモリ | 16,000 KB |
| 最終ジャッジ日時 | 2024-07-08 03:21:09 |
| 合計ジャッジ時間 | 7,027 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 1 TLE * 1 -- * 33 |
ソースコード
n,e = map(int,input().split())
a = list(map(int,input()))
buy = 0
count = 0
bonus = 0
for i in range(e):
if count == e:
break
for j in range(n):
count += 1
if bonus == 0:
buy +=1
else:
bonus -= 1
bonus += a[j]
if count == e:
break
print(buy)