結果
| 問題 | No.3472 ジャッジキューの待ち時間クエリ |
| コンテスト | |
| ユーザー |
Kude
|
| 提出日時 | 2026-03-06 21:36:08 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 532 ms / 2,000 ms |
| コード長 | 230 bytes |
| 記録 | |
| コンパイル時間 | 2,533 ms |
| コンパイル使用メモリ | 85,076 KB |
| 実行使用メモリ | 113,620 KB |
| 最終ジャッジ日時 | 2026-03-06 23:25:23 |
| 合計ジャッジ時間 | 7,690 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
| サブタスク | 配点 | 結果 |
|---|---|---|
| サンプル | 10 点 | AC * 3 |
| Small | 30 点 | AC * 7 |
| Large | 60 点 | AC * 7 |
| 合計 | 100 点 |
ソースコード
from bisect import bisect_right
from itertools import accumulate
n, q = map(int, input().split())
t = list(accumulate(map(int, input().split()), initial=0))
for _ in range(q):
x = int(input())
print(bisect_right(t, x) - 1)
Kude