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;
struct el {
  long long val;
  int poz;
  bool operator<(const el &A) const { return val < A.val; }
};
el v[1000005];
long long a[1000005];
struct nr {
  int maxim, poz;
};
nr aib1[1000005], aib2[1000005];
int n, dp[1000005], t[1000005], soll[1000005];
inline void Normalize() {
  int i;
  sort(v + 1, v + n + 1);
  a[v[1].poz] = 1;
  for (i = 2; i <= n; ++i)
    if (v[i].val == v[i - 1].val)
      a[v[i].poz] = a[v[i - 1].poz];
    else
      a[v[i].poz] = a[v[i - 1].poz] + 1;
}
inline void Update1(int x, nr y) {
  for (int i = x; i <= n; i += (i & (-i)))
    if (aib1[i].maxim < y.maxim) aib1[i] = y;
}
inline void Update2(int x, nr y) {
  for (int i = x; i > 0; i -= (i & (-i)))
    if (aib2[i].maxim < y.maxim) aib2[i] = y;
}
inline nr Query1(int x) {
  nr s;
  s.maxim = 0;
  for (int i = x; i > 0; i -= (i & (-i)))
    if (s.maxim < aib1[i].maxim) s = aib1[i];
  return s;
}
inline nr Query2(int x) {
  nr s;
  s.maxim = 0;
  for (int i = x; i <= n; i += (i & (-i)))
    if (s.maxim < aib2[i].maxim) s = aib2[i];
  return s;
}
int main() {
  int i, len, sol = 0, d, possol;
  nr w;
  cin >> n >> d;
  for (i = 1; i <= n; ++i) {
    cin >> a[i];
    v[i].val = a[i];
    v[i].poz = i;
  }
  len = n;
  for (i = 1; i <= len; ++i) {
    a[++n] = a[i] - d;
    v[n].val = a[i] - d;
    v[n].poz = n;
    a[++n] = a[i] + d;
    v[n].val = a[i] + d;
    v[n].poz = n;
  }
  Normalize();
  for (i = 1; i <= len; ++i) {
    dp[i] = 1;
    t[i] = 0;
    w = Query1(a[len + 2 * i - 1]);
    if (dp[i] < w.maxim + 1) {
      dp[i] = w.maxim + 1;
      t[i] = w.poz;
    }
    w = Query2(a[len + 2 * i]);
    if (dp[i] < w.maxim + 1) {
      dp[i] = w.maxim + 1;
      t[i] = w.poz;
    }
    if (sol < dp[i]) {
      sol = dp[i];
      possol = i;
    }
    w.maxim = dp[i];
    w.poz = i;
    Update1(a[i], w);
    Update2(a[i], w);
  }
  cout << sol << "\n";
  for (i = possol; i; i = t[i]) soll[++soll[0]] = i;
  for (i = soll[0]; i; --i) cout << soll[i] << " ";
  cout << "\n";
  return 0;
}
