#include <bits/stdc++.h>
const long long int hell = 998244353;
using namespace std;
void solve() {
  long long int n, c;
  cin >> n >> c;
  long long int ans = 1;
  long long int l = 0;
  for (long long int i = 0; i < n; i++) {
    long long int t;
    cin >> t;
    if (i) {
      if (t - l > c) {
        ans = 1;
      } else
        ans++;
      l = t;
    } else
      l = t;
  }
  cout << ans;
}
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long int T;
  T = 1;
  while (T--) {
    solve();
  }
  return 0;
}
