結果
問題 |
No.878 Range High-Element Query
|
ユーザー |
![]() |
提出日時 | 2019-10-30 19:51:38 |
言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
結果 |
TLE
|
実行時間 | - |
コード長 | 562 bytes |
コンパイル時間 | 224 ms |
コンパイル使用メモリ | 12,544 KB |
実行使用メモリ | 23,788 KB |
最終ジャッジ日時 | 2024-09-14 21:56:12 |
合計ジャッジ時間 | 4,363 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 |
other | AC * 10 TLE * 1 -- * 7 |
ソースコード
class No878: def get_date(self): return list(map(int,input().split())) def count_highest(self,x): k, t = 0, 0 for i in range(len(x)): if x[i] > t: k += 1 t = x[i] print(k) def solve(self): n, q = self.get_date() a = self.get_date() for _ in range(q): query = self.get_date() l, r = query[1:] b = a[l - 1: r] self.count_highest(b) if __name__ == "__main__": pro = No878() pro.solve()