#include <bits/stdc++.h>
using namespace std;
int a[100001];
int main() {
  int n, c, i;
  cin >> n >> c;
  for (i = 1; i <= n; i++) cin >> a[i];
  for (i = n; i >= 2; i--)
    if (a[i] - a[i - 1] > c) break;
  cout << n - i + 1;
  return 0;
}
