import sys input = sys.stdin.readline N, K = map(int, input().split()) X = list(map(int, input().split())) A = [X[0]] for x in X[1:]: if x-A[-1]>=K: A.append(x) print(len(A))