#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 9;
int arr[maxn];
int main() {
  int a, b, c, d, e, f, g, h;
  scanf("%d%d", &a, &c);
  for (d = 1; d <= a; d++) scanf("%d", &arr[d]);
  for (d = a; d > 1; d--) {
    if (arr[d] - arr[d - 1] > c) break;
  }
  printf("%d\n", a - d + 1);
  return 0;
}
