結果

問題 No.1110 好きな歌
ユーザー Akijin_007Akijin_007
提出日時 2022-11-04 14:14:45
言語 PyPy3
(7.3.15)
結果
AC  
実行時間 310 ms / 5,000 ms
コード長 316 bytes
コンパイル時間 390 ms
コンパイル使用メモリ 86,772 KB
実行使用メモリ 83,712 KB
最終ジャッジ日時 2023-09-25 17:34:56
合計ジャッジ時間 16,259 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 70 ms
71,212 KB
testcase_01 AC 69 ms
71,112 KB
testcase_02 AC 70 ms
71,212 KB
testcase_03 AC 71 ms
71,132 KB
testcase_04 AC 70 ms
71,492 KB
testcase_05 AC 70 ms
71,284 KB
testcase_06 AC 69 ms
71,232 KB
testcase_07 AC 71 ms
71,264 KB
testcase_08 AC 71 ms
71,184 KB
testcase_09 AC 70 ms
71,496 KB
testcase_10 AC 71 ms
71,516 KB
testcase_11 AC 69 ms
71,528 KB
testcase_12 AC 70 ms
71,316 KB
testcase_13 AC 70 ms
71,212 KB
testcase_14 AC 86 ms
76,044 KB
testcase_15 AC 80 ms
75,404 KB
testcase_16 AC 81 ms
76,008 KB
testcase_17 AC 88 ms
76,008 KB
testcase_18 AC 72 ms
71,232 KB
testcase_19 AC 92 ms
76,552 KB
testcase_20 AC 87 ms
76,028 KB
testcase_21 AC 80 ms
75,232 KB
testcase_22 AC 86 ms
76,004 KB
testcase_23 AC 78 ms
75,444 KB
testcase_24 AC 222 ms
80,476 KB
testcase_25 AC 236 ms
81,276 KB
testcase_26 AC 180 ms
80,164 KB
testcase_27 AC 240 ms
81,860 KB
testcase_28 AC 177 ms
80,368 KB
testcase_29 AC 274 ms
82,208 KB
testcase_30 AC 167 ms
80,264 KB
testcase_31 AC 151 ms
79,004 KB
testcase_32 AC 286 ms
82,988 KB
testcase_33 AC 173 ms
80,284 KB
testcase_34 AC 233 ms
81,292 KB
testcase_35 AC 256 ms
83,644 KB
testcase_36 AC 124 ms
78,504 KB
testcase_37 AC 160 ms
79,016 KB
testcase_38 AC 269 ms
82,660 KB
testcase_39 AC 230 ms
81,156 KB
testcase_40 AC 220 ms
82,140 KB
testcase_41 AC 120 ms
77,984 KB
testcase_42 AC 248 ms
82,780 KB
testcase_43 AC 270 ms
82,336 KB
testcase_44 AC 269 ms
83,436 KB
testcase_45 AC 304 ms
83,448 KB
testcase_46 AC 283 ms
83,648 KB
testcase_47 AC 305 ms
83,584 KB
testcase_48 AC 285 ms
83,208 KB
testcase_49 AC 250 ms
83,712 KB
testcase_50 AC 284 ms
83,452 KB
testcase_51 AC 272 ms
83,424 KB
testcase_52 AC 291 ms
83,236 KB
testcase_53 AC 310 ms
83,432 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#int(input())
#map(int, input().split())
#list(map(int, input().split()))

N, D = map(int, input().split())
A = [0] * N
for i in range(N):
    A[i] = int(input())

B = sorted(A)

import bisect

ans = [0] * N
for i in range(N):
    t = bisect.bisect(B, A[i]-D)
    ans[i] = t

for i in range(N):
    print(ans[i])



0