結果
| 問題 |
No.2774 Wake up Record 2
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-02-19 13:27:20 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 95 ms / 2,000 ms |
| コード長 | 332 bytes |
| コンパイル時間 | 1,920 ms |
| コンパイル使用メモリ | 82,024 KB |
| 実行使用メモリ | 97,024 KB |
| 最終ジャッジ日時 | 2025-02-19 13:27:25 |
| 合計ジャッジ時間 | 3,127 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 16 |
ソースコード
import bisect
n,k=map(int,input().split())
A=list(map(int,input().split()))
As=sorted(A)
l,r=0,10**9
while r-l>1:
c=(r+l)//2
if bisect.bisect_right(As,c)>=k:
r=c
else:
l=c
ans=[i>r for i in A]
Ans=[]
for i in range(n-1):
if not ans[i] and ans[i+1]:
Ans.append(i+2)
print(len(Ans))
print(*Ans)