#include <bits/stdc++.h>
using namespace std;
template <typename T>
inline T fromString(const string &s) {
  T res;
  istringstream iss(s);
  iss >> res;
  return res;
};
template <typename T>
inline string toString(const T &a) {
  ostringstream oss;
  oss << a;
  return oss.str();
};
template <typename T = int>
inline void dump(vector<T> vs, bool ent = false) {
  for (int i = 0; i < (int)(vs.size()); i++)
    cout << vs[i] << (i + 1 == vs.size() ? '\n' : ' ');
  if (ent) cout << endl;
}
template <typename T = int>
inline void dump(vector<vector<T>> vs, bool ent = false) {
  for (int i = 0; i < (int)(vs.size()); i++) dump<T>(vs[i]);
  if (ent) cout << endl;
}
const int INF = 0x3f3f3f3f;
const long long INFL = 0x3f3f3f3f3f3f3f3fLL;
const double DINF = 0x3f3f3f3f;
const int DX[] = {1, 0, -1, 0};
const int DY[] = {0, -1, 0, 1};
const double EPS = 1e-12;
template <typename T = int>
inline T in() {
  T x;
  cin >> x;
  return x;
}
template <typename T = int>
inline vector<T> in(int n) {
  vector<T> xs(n);
  for (int i = 0; i < (int)(n); i++) cin >> xs[i];
  return xs;
}
template <typename T = int>
inline vector<vector<T>> in(int n, int m) {
  vector<vector<T>> xs(n, vector<T>(m));
  for (int i = 0; i < (int)(n); i++)
    for (int j = 0; j < (int)(m); j++) cin >> xs[i][j];
  return xs;
}
int main(void) {
  int n = in(), c = in();
  vector<int> ts = in(n);
  int cnt = 1;
  for (int i = (1); i < (int)(n); i++) {
    if (ts[i] - ts[i - 1] > c) cnt = 0;
    ++cnt;
  }
  cout << cnt << endl;
  return 0;
}
