Marmot found a row with n pillars. The i-th pillar has the height of hi meters. Starting from one pillar i1, Marmot wants to jump on the pillars i2, ..., ik. (1 ≤ i1 < i2 < ... < ik ≤ n). From a pillar i Marmot can jump on a pillar j only if i < j and |hi - hj| ≥ d, where |x| is the absolute value of the number x.

Now Marmot is asking you find out a jump sequence with maximal length and print it.

Input

The first line contains two integers n and d (1 ≤ n ≤ 105, 0 ≤ d ≤ 109).

The second line contains n numbers h1, h2, ..., hn (1 ≤ hi ≤ 1015).

Output

The first line should contain one integer k, the maximal length of a jump sequence.

The second line should contain k integers i1, i2, ..., ik (1 ≤ i1 < i2 < ... < ik ≤ n), representing the pillars' indices from the maximal length jump sequence.

If there is more than one maximal length jump sequence, print any.

Examples

Input

5 2
1 3 6 7 4


Output

4
1 2 3 5 


Input

10 3
2 1 3 6 9 11 7 3 20 18


Output

6
1 4 6 7 8 9 

Note

In the first example Marmot chooses the pillars 1, 2, 3, 5 with the heights 1, 3, 6, 4. Another jump sequence of length 4 is 1, 2, 4, 5.
#include <bits/stdc++.h>
using namespace std;
const long long inf = 1e17;
const long long N = 1e5 + 100;
const long long bits = 21;
const long long mod = 1e9 + 7;
const long double pi = 3.14159265358979323846;
long long tree[4 * N], ans[N], store[N];
void build(long long ss, long long se, long long si) {
  tree[si] = -1;
  if (ss == se) {
    return;
  }
  long long mid = (ss + se) / 2;
  build(ss, mid, 2 * si + 1);
  build(mid + 1, se, 2 * si + 2);
}
long long query(long long qs, long long qe, long long ss, long long se,
                long long si) {
  if (qs > se || qe < ss || qs > qe || ss > se) {
    return -1;
  }
  if (ss >= qs && se <= qe) {
    return tree[si];
  }
  long long mid = (se + ss) / 2;
  long long left = query(qs, qe, ss, mid, 2 * si + 1);
  long long right = query(qs, qe, mid + 1, se, 2 * si + 2);
  if (left == -1) {
    return right;
  } else if (right == -1) {
    return left;
  } else {
    if (ans[left] > ans[right]) {
      return left;
    } else {
      return right;
    }
  }
  return -1;
}
void upd(long long qs, long long qe, long long ss, long long se, long long si,
         long long val) {
  if (qs > se || qe < ss || qs > qe || ss > se) {
    return;
  }
  if (ss >= qs && se <= qe) {
    tree[si] = val;
    return;
  }
  long long mid = (se + ss) / 2;
  upd(qs, qe, ss, mid, 2 * si + 1, val);
  upd(qs, qe, mid + 1, se, 2 * si + 2, val);
  if (tree[2 * si + 1] == -1) {
    tree[si] = tree[2 * si + 2];
  } else if (tree[2 * si + 2] == -1) {
    tree[si] = tree[2 * si + 1];
  } else {
    if (ans[tree[2 * si + 1]] > ans[tree[2 * si + 2]]) {
      tree[si] = tree[2 * si + 1];
    } else {
      tree[si] = tree[2 * si + 2];
    }
  }
  return;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  ;
  std::cout << std::fixed << std::setprecision(20);
  ;
  long long n, d;
  cin >> n >> d;
  vector<long long> h(n), h1(n);
  map<long long, long long> mp;
  for (int i = 0; i < n; i++) {
    cin >> h[i];
    h1[i] = h[i];
  }
  build(0, n, 0);
  sort(h1.begin(), h1.end());
  for (int i = 0; i < n; i++) {
    mp[h[i]] = lower_bound(h1.begin(), h1.end(), h[i]) - h1.begin();
  }
  for (int i = n - 1; i >= 0; i--) {
    long long val = 1;
    long long mi = h[i] - d;
    long long ma = d + h[i];
    long long lp = lower_bound(h1.begin(), h1.end(), mi) - h1.begin();
    long long hp = lower_bound(h1.begin(), h1.end(), ma) - h1.begin();
    while (lp >= 0 && h[i] - h1[lp] < d) {
      lp--;
    }
    long long a1 = -1;
    long long a2 = -1;
    ans[i] = 1;
    store[i] = i;
    if (lp != -1) a1 = query(0, mp[h1[lp]], 0, n, 0);
    if (hp != n) a2 = query(mp[h1[hp]], n, 0, n, 0);
    if (a1 != -1) {
      if (a2 != -1) {
        if (ans[i] < max(ans[a1], ans[a2]) + 1) {
          if (ans[a1] + 1 > ans[a2]) {
            ans[i] = ans[a1] + 1;
            store[i] = a1;
          } else {
            ans[i] = ans[a2] + 1;
            store[i] = a2;
          }
        }
      } else {
        if (ans[a1] + 1 > ans[i]) {
          ans[i] = ans[a1] + 1;
          store[i] = a1;
        }
      }
    } else {
      if (a2 != -1) {
        if (ans[i] < ans[a2] + 1) {
          ans[i] = ans[a2] + 1;
          store[i] = a2;
        }
      }
    }
    upd(mp[h[i]], mp[h[i]], 0, n, 0, i);
  }
  long long x = ans[0];
  for (int i = 0; i < n; i++) {
    if (ans[x] < ans[i]) {
      x = i;
    }
  }
  cout << ans[x] << "\n";
  while (ans[x] != 1) {
    cout << x + 1 << " ";
    x = store[x];
  }
  cout << x + 1 << "\n";
}
