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 double pi = acos(-1.0);
const double eps = 1e-6;
const int mod = 1e9 + 7;
const int inf = 1e9;
const int maxn = 2e5 + 100;
inline long long read() {
  long long x = 0, f = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return x * f;
}
long long qpow(long long a, long long b) {
  long long res = 1;
  a %= mod;
  assert(b >= 0);
  for (; b; b >>= 1) {
    if (b & 1) res = res * a % mod;
    a = a * a % mod;
  }
  return res;
}
long long n, d;
long long a[maxn];
long long t[maxn];
long long dp[maxn];
long long pre[maxn];
struct node {
  int l, r;
  pair<long long, long long> sum;
} segTree[maxn << 2];
void build(int i, int l, int r) {
  segTree[i].l = l;
  segTree[i].r = r;
  segTree[i].sum.first = -1;
  segTree[i].sum.second = -1;
  if (l == r) {
    return;
  }
  int mid = (l + r) >> 1;
  build(i << 1, l, mid);
  build(i << 1 | 1, mid + 1, r);
  segTree[i].sum = max(segTree[i << 1].sum, segTree[i << 1 | 1].sum);
}
void up(int i, long long p, long long v, long long pre) {
  if (segTree[i].l == p && segTree[i].r == p) {
    segTree[i].sum = max(segTree[i].sum, make_pair(v, pre));
    return;
  }
  long long mid = (segTree[i].l + segTree[i].r) >> 1;
  if (p <= mid) up(i << 1, p, v, pre);
  if (p > mid) up(i << 1 | 1, p, v, pre);
  segTree[i].sum = max(segTree[i << 1].sum, segTree[i << 1 | 1].sum);
}
pair<long long, long long> query(int i, int l, int r) {
  if (l > r) return make_pair(-1ll, -1ll);
  if (segTree[i].l >= l && segTree[i].r <= r) return segTree[i].sum;
  int mid = (segTree[i].l + segTree[i].r) >> 1;
  pair<long long, long long> ans = make_pair(0ll, 0ll);
  if (l <= mid) ans = max(ans, query(i << 1, l, r));
  if (r > mid) ans = max(ans, query(i << 1 | 1, l, r));
  return ans;
}
int main() {
  n = read(), d = read();
  for (int i = 1; i <= n; i++) a[i] = read(), t[i] = a[i];
  sort(t + 1, t + n + 1);
  int m = unique(t + 1, t + n + 1) - t - 1;
  for (int i = 1; i <= n; i++)
    a[i] = upper_bound(t + 1, t + m + 1, a[i]) - t - 1;
  build(1, 1, m + 1);
  for (int i = 1; i <= n; i++) {
    int Min = upper_bound(t + 1, t + m + 1, t[a[i]] - d) - t;
    int Max = lower_bound(t + 1, t + m + 1, t[a[i]] + d) - t;
    Min--;
    pair<long long, long long> t1 = query(1, 1, Min);
    if (t1.first + 1 > dp[i]) {
      dp[i] = t1.first + 1;
      pre[i] = t1.second;
    }
    pair<long long, long long> t2 = query(1, Max, m);
    if (t2.first + 1 > dp[i]) {
      dp[i] = t2.first + 1;
      pre[i] = t2.second;
    }
    up(1, a[i], dp[i], i);
  }
  long long ans = 0, u = -1;
  for (int i = 1; i <= n; i++) {
    if (dp[i] > ans) {
      ans = dp[i];
      u = i;
    }
  }
  printf("%lld\n", ans);
  vector<int> wjm;
  while (u) {
    wjm.push_back(u);
    u = pre[u];
  }
  reverse(wjm.begin(), wjm.end());
  for (int v : wjm) printf("%d ", v);
  printf("\n");
}
