結果

問題 No.1110 好きな歌
ユーザー ryusukeryusuke
提出日時 2022-01-30 15:52:06
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 324 ms / 5,000 ms
コード長 212 bytes
コンパイル時間 665 ms
コンパイル使用メモリ 87,240 KB
実行使用メモリ 82,600 KB
最終ジャッジ日時 2023-09-02 01:40:16
合計ジャッジ時間 18,213 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 74 ms
71,444 KB
testcase_01 AC 72 ms
71,496 KB
testcase_02 AC 72 ms
71,428 KB
testcase_03 AC 75 ms
71,328 KB
testcase_04 AC 73 ms
71,500 KB
testcase_05 AC 71 ms
71,588 KB
testcase_06 AC 73 ms
71,512 KB
testcase_07 AC 74 ms
71,364 KB
testcase_08 AC 74 ms
71,304 KB
testcase_09 AC 74 ms
71,364 KB
testcase_10 AC 73 ms
71,476 KB
testcase_11 AC 72 ms
71,360 KB
testcase_12 AC 75 ms
71,324 KB
testcase_13 AC 73 ms
71,408 KB
testcase_14 AC 87 ms
76,256 KB
testcase_15 AC 84 ms
75,420 KB
testcase_16 AC 88 ms
76,052 KB
testcase_17 AC 92 ms
76,064 KB
testcase_18 AC 75 ms
71,432 KB
testcase_19 AC 93 ms
76,152 KB
testcase_20 AC 91 ms
76,088 KB
testcase_21 AC 84 ms
75,676 KB
testcase_22 AC 90 ms
76,140 KB
testcase_23 AC 81 ms
75,620 KB
testcase_24 AC 220 ms
80,052 KB
testcase_25 AC 245 ms
80,684 KB
testcase_26 AC 189 ms
79,616 KB
testcase_27 AC 246 ms
80,456 KB
testcase_28 AC 185 ms
79,928 KB
testcase_29 AC 294 ms
81,348 KB
testcase_30 AC 174 ms
79,824 KB
testcase_31 AC 158 ms
79,200 KB
testcase_32 AC 298 ms
81,420 KB
testcase_33 AC 177 ms
79,896 KB
testcase_34 AC 233 ms
80,532 KB
testcase_35 AC 262 ms
82,356 KB
testcase_36 AC 127 ms
77,824 KB
testcase_37 AC 166 ms
78,956 KB
testcase_38 AC 289 ms
81,540 KB
testcase_39 AC 239 ms
80,540 KB
testcase_40 AC 224 ms
81,112 KB
testcase_41 AC 123 ms
77,932 KB
testcase_42 AC 255 ms
82,160 KB
testcase_43 AC 283 ms
80,872 KB
testcase_44 AC 273 ms
82,212 KB
testcase_45 AC 313 ms
82,216 KB
testcase_46 AC 288 ms
82,600 KB
testcase_47 AC 324 ms
82,104 KB
testcase_48 AC 299 ms
82,356 KB
testcase_49 AC 255 ms
82,292 KB
testcase_50 AC 297 ms
82,116 KB
testcase_51 AC 282 ms
82,404 KB
testcase_52 AC 300 ms
81,908 KB
testcase_53 AC 322 ms
82,324 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from bisect import bisect_right

n, d = map(int, input().split())
a = [int(input()) for _ in range(n)]
p = [i for i in a]
p.sort()

# Ai - d >= aj
for i in range(n):
    t = bisect_right(p, a[i] - d)
    print(t)
0