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 int N = 100100;
long long int arr[N];
int dp[100005];
struct node {
  pair<long long int, long long int> maxi;
  inline void combine(const node& left, const node& right) {
    maxi = max(left.maxi, right.maxi);
  }
} tree[N << 2];
struct segmentTree {
  int n;
  segmentTree(int m) : n(m) { build(0, 0, n - 1); }
  void build(int x, int l, int r) {
    if (l == r) {
      tree[x].maxi = make_pair(0, -1);
      return;
    }
    int m = (l + r) >> 1;
    build((x << 1) + 1, l, m);
    build((x << 1) + 2, m + 1, r);
    tree[x].combine(tree[(x << 1) + 1], tree[(x << 1) + 2]);
  }
  void update(int x, int l, int r, int pos,
              pair<long long int, long long int> v) {
    if (l == pos and r == pos) {
      tree[x].maxi = v;
      return;
    }
    int m = ((l + r) >> 1);
    if (pos <= m)
      update((x << 1) + 1, l, m, pos, v);
    else
      update((x << 1) + 2, m + 1, r, pos, v);
    tree[x].combine(tree[(x << 1) + 1], tree[(x << 1) + 2]);
  }
  node query(int x, int l, int r, int ql, int qr) {
    if (l >= ql && r <= qr) return tree[x];
    int m = ((l + r) >> 1);
    if (qr <= m) return query((x << 1) + 1, l, m, ql, qr);
    if (ql > m) return query((x << 1) + 2, m + 1, r, ql, qr);
    node ret;
    ret.combine(query((x << 1) + 1, l, m, ql, qr),
                query((x << 1) + 2, m + 1, r, ql, qr));
    return ret;
  }
  void update(int pos, pair<long long int, long long int> v) {
    update(0, 0, n - 1, pos, v);
  }
  node query(int ql, int qr) { return query(0, 0, n - 1, ql, qr); }
};
int parent[100005];
int main() {
  int n, d;
  cin >> n >> d;
  segmentTree T(n);
  memset(dp, 0, sizeof dp);
  vector<long long int> store;
  for (int i = 0, _i = (n); i < _i; ++i) {
    cin >> arr[i];
    store.push_back(arr[i]);
  }
  sort((store).begin(), (store).end());
  store.erase(unique((store).begin(), (store).end()), store.end());
  memset(parent, -1, sizeof parent);
  dp[0] = 1;
  int index =
      lower_bound((store).begin(), (store).end(), arr[0]) - store.begin();
  T.update(index, make_pair(1, 0));
  for (int i = 1; i < n; i++) {
    long long int low = arr[i] - d;
    long long int high = arr[i] + d;
    int l = lower_bound((store).begin(), (store).end(), low) - store.begin();
    node q1, q2, te;
    te.maxi = make_pair(0, 0);
    if (store[l] != low) {
      if (l == 0)
        q1 = te;
      else
        q1 = T.query(0, l - 1);
    } else {
      q1 = T.query(0, l);
    }
    int h = lower_bound((store).begin(), (store).end(), high) - store.begin();
    if (h == n)
      q2 = te;
    else
      q2 = T.query(h, n - 1);
    if (q1.maxi.first == 0 and q2.maxi.first == 0)
      ;
    else {
      if (q1.maxi.first > q2.maxi.first)
        parent[i] = q1.maxi.second;
      else
        parent[i] = q2.maxi.second;
    }
    dp[i] = 1 + max(q1.maxi.first, q2.maxi.first);
    index = lower_bound((store).begin(), (store).end(), arr[i]) - store.begin();
    T.update(index, make_pair(dp[i], i));
  }
  int curr = -2147483647;
  int ind;
  for (int i = 0, _i = (n); i < _i; ++i) {
    if (dp[i] > curr) {
      curr = dp[i];
      ind = i;
    }
  }
  cout << dp[ind] << endl;
  vector<long long int> tem;
  while (true) {
    if (ind == -1) break;
    tem.push_back(ind + 1);
    ind = parent[ind];
  }
  reverse((tem).begin(), (tem).end());
  for (int i = 0, _i = (int((tem).size())); i < _i; ++i) cout << tem[i] << " ";
  cout << endl;
  return 0;
}
