結果
| 問題 |
No.2942 Sigma Music Game Level Problem
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-03-03 12:43:57 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 554 bytes |
| コンパイル時間 | 398 ms |
| コンパイル使用メモリ | 82,752 KB |
| 実行使用メモリ | 67,580 KB |
| 最終ジャッジ日時 | 2025-03-03 12:44:06 |
| 合計ジャッジ時間 | 4,971 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | RE * 3 |
| other | RE * 24 |
ソースコード
from atcoder.fenwicktree import FenwickTree
n,q,l0=map(int,input().split())
a=list(map(int,input().split()))
kind=FenwickTree(2*10**5+10)
level=FenwickTree(2*10**5+10)
for i in range(n):
kind.add(a[i],1)
level.add(a[i],a[i])
cnt=0
for _ in range(q):
query=list(map(int,input().split()))
if query[0]==1:
que,num=query
kind.add(num,1)
level.add(num,num)
elif query[0]==2:
cnt+=1
que,left,right=query
print(kind.sum(left,right+1),level.sum(left,right+1))
if cnt==0:
print("Not Found!")