結果
問題 | No.2961 Shiny Monster Master |
ユーザー |
![]() |
提出日時 | 2024-11-16 15:34:58 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 152 ms / 1,777 ms |
コード長 | 285 bytes |
コンパイル時間 | 427 ms |
コンパイル使用メモリ | 82,304 KB |
実行使用メモリ | 89,856 KB |
最終ジャッジ日時 | 2024-11-16 15:35:09 |
合計ジャッジ時間 | 11,056 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 77 |
ソースコード
from bisect import bisect_left, bisect_right r, n = map(int, input().split()) a = sorted(map(int, input().split())) def f(x): x, y = divmod(x, r) return x * n + bisect_left(a, y) for _ in range(int(input())): li, ri = map(int, input().split()) print(f(ri + 1) - f(li))