#include <bits/stdc++.h>
int main() {
  int n, i, b[100], k = 0, c = 0, j;
  scanf("%d%d", &n, &k);
  for (i = 1; i <= n; i++) {
    scanf("%d", &b[i]);
  }
  for (i = 1; i <= n; i++) {
    j = b[i] - b[i + 1];
    if (j < 0) j = j - (2 * j);
    if (j <= k) c++;
  }
  printf("%d\n", c + 1);
  return 0;
}
