#include <bits/stdc++.h>
using namespace std;
long long INF = 9e18;
int a[100005];
int main() {
  int n, c;
  cin >> n >> c;
  for (int i = 0; i < n; i++) cin >> a[i];
  int ans = 1;
  for (int i = 1; i < n; i++) {
    if (a[i] - a[i - 1] > c) {
      ans = 0;
    }
    ans++;
  }
  cout << ans << endl;
}
