fun main() { var (n, K) = readln().split(" ").map { it.toInt() } var x = readln().split(" ").map { it.toInt() } var postn = 1 var j = 2 var i = 1 while (j <= n){ if ( (x[j] - x[i]) >= K ) { postn = postn + 1 i = j j = j+1 } if(i==n){postn = postn - 1 } j = j+1 } println (postn) }