結果

問題 No.1110 好きな歌
ユーザー tikitaka1201
提出日時 2020-07-11 11:34:39
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 321 ms / 5,000 ms
コード長 195 bytes
コンパイル時間 380 ms
コンパイル使用メモリ 82,304 KB
実行使用メモリ 84,648 KB
最終ジャッジ日時 2024-10-12 20:42:59
合計ジャッジ時間 11,513 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 51
権限があれば一括ダウンロードができます

ソースコード

diff #

n,d=map(int,input().split())
a=[]
for _ in range(n):
    a.append(int(input()))
import bisect
sorta=sorted(a)

for i in range(n):
    x=a[i]-d
    ans=bisect.bisect_right(sorta, x)
    print(ans)
0