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;
vector<pair<long long int, int> > b;
int bn_srch1(int start, int end, long long int x);
int bn_srch2(int start, int end, long long int x);
int qi, qe;
int query1(int start, int end, int i) {
  int mid = (start + end) / 2;
  int temp1, temp2;
  if (qe < start || qi > end) return -1;
  if (start == end) return i;
  if (qi <= start && end <= qe) {
    return i;
  }
  temp1 = query1(start, mid, 2 * i + 1);
  temp2 = query1(mid + 1, end, 2 * i + 2);
  if (temp1 == -1 || temp2 == -1) {
    if (temp1 == -1) {
      return temp2;
    } else
      return temp1;
  } else {
    if (b[temp1].first > b[temp2].first) {
      return temp1;
    } else
      return temp2;
  }
}
long long int x, updatenum, pos;
int update(int start, int end, int i) {
  int mid = (start + end) / 2;
  if (start == end) {
    b[i].first = updatenum;
    b[i].second = pos;
    return 0;
  } else if (x <= mid) {
    update(start, mid, 2 * i + 1);
  } else if (x > mid) {
    update(mid + 1, end, 2 * i + 2);
  }
  if (b[2 * i + 1].first > b[2 * i + 2].first) {
    b[i].first = b[2 * i + 1].first;
    b[i].second = b[2 * i + 1].second;
  } else {
    b[i].first = b[2 * i + 2].first;
    b[i].second = b[2 * i + 2].second;
  }
  return 0;
}
vector<pair<long long int, int> > vec;
int position[100001], findmin[100001], findmax[100001];
long long int a[100001];
int max2[100001];
int main() {
  int i, n, d, j;
  long long int l, max1, min1;
  for (i = 1; i <= 200001; i++) b.push_back(pair<long long int, int>());
  cin >> n >> d;
  for (i = 1; i <= n; i++) {
    cin >> l;
    a[i] = l;
    vec.push_back(pair<long long int, int>(l, i));
  }
  sort(vec.begin(), vec.end());
  for (i = 0; i < n; i++) {
    position[vec[i].second] = i + 1;
  }
  for (i = 1; i <= n; i++) {
    findmin[i] = bn_srch1(0, n - 1, a[i] - d);
    findmax[i] = bn_srch2(0, n - 1, a[i] + d);
  }
  for (i = 1; i <= n; i++) {
    int temp1 = 0, temp2 = 0;
    if (findmin[i] == -1)
      min1 = 0;
    else {
      qi = 1;
      qe = findmin[i];
      temp1 = query1(1, n, 0);
      min1 = b[temp1].first;
    }
    if (findmax[i] == -1)
      max1 = 0;
    else {
      {
        qi = findmax[i];
        qe = n;
        temp2 = query1(1, n, 0);
        max1 = b[temp2].first;
      }
    }
    if (max1 == min1 && max1 == 0)
      max2[i] = i;
    else {
      if (max1 > min1)
        max2[i] = b[temp2].second;
      else {
        max2[i] = b[temp1].second;
      }
    }
    updatenum = 1 + max(max1, min1);
    x = position[i];
    pos = i;
    update(1, n, 0);
  }
  vector<int> vec1;
  cout << b[0].first;
  cout << endl;
  j = b[0].second;
  while (j != max2[j]) {
    vec1.push_back(j);
    j = max2[j];
  }
  vec1.push_back(j);
  for (i = vec1.size() - 1; i >= 0; i--) cout << vec1[i] << " ";
  cout << endl;
}
int bn_srch1(int start, int end, long long int x) {
  if (start == end) return start + 1;
  if (x > vec[end].first)
    return end + 1;
  else if (x < vec[start].first)
    return -1;
  int mid = (start + end) / 2;
  if (vec[mid].first < x && vec[mid + 1].first > x)
    return mid + 1;
  else if (x > vec[mid].first)
    bn_srch1(mid, end, x);
  else if (x < vec[mid].first)
    bn_srch1(start, mid, x);
  else if (mid + 1 <= end && x == vec[mid].first && x == vec[mid + 1].first)
    bn_srch1(mid + 1, end, x);
  else if (mid + 1 <= end && x == vec[mid].first && x < vec[mid + 1].first)
    return mid + 1;
  else
    return -1;
}
int bn_srch2(int start, int end, long long int x) {
  if (x > vec[end].first)
    return -1;
  else if (x < vec[start].first)
    return start + 1;
  int mid = (start + end) / 2;
  if (start == end)
    return start + 1;
  else if (start > end)
    return -1;
  else if (end == start + 1) {
    if (vec[mid].first == x)
      return mid + 1;
    else
      return mid + 2;
  }
  if (vec[mid].first < x && vec[mid + 1].first > x)
    return mid + 2;
  else if (x > vec[mid].first)
    bn_srch2(mid + 1, end, x);
  else if (x < vec[mid].first)
    bn_srch2(start, mid, x);
  else if (mid - 1 >= start && x == vec[mid - 1].first && x == vec[mid].first)
    bn_srch2(start, mid - 1, x);
  else if (mid - 1 >= start && x > vec[mid - 1].first && x == vec[mid].first)
    return mid + 1;
  else
    return -1;
}
