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.
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.List;
import java.util.Arrays;
import java.util.SplittableRandom;
import java.util.InputMismatchException;
import java.io.IOException;
import java.util.Collections;
import java.util.ArrayList;
import java.io.InputStream;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author Pradyumn
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        FastReader in = new FastReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        TaskE solver = new TaskE();
        solver.solve(1, in, out);
        out.close();
    }

    static class TaskE {
        static TaskE.Pair[] seg;
        static final int oo = Integer.MAX_VALUE >> 1;
        static int n;
        static int d;
        static long[] a;
        static long[] b;
        static int[] dp;
        static int[] prev;

        public void solve(int testNumber, FastReader in, PrintWriter out) {
            n = in.nextInt();
            d = in.nextInt();
            a = in.nextLongArray(n);
            b = a.clone();
            seg = new TaskE.Pair[4 * n];
            ArrayUtils.sort(b);
            build(0, n - 1, 0);
            dp = new int[n];
            ArrayUtils.fill(dp, 1);
            prev = new int[n];
            ArrayUtils.fill(prev, -1);
            for (int i = 0; i < n; ++i) {
                int low = -1;
                int high = n;
                while (high - low > 1) {
                    int mid = (high + low) >>> 1;
                    if (b[mid] <= a[i] - d) {
                        low = mid;
                    } else {
                        high = mid;
                    }
                }
                if (low != -1) {
                    TaskE.Pair pair = query(0, low);
                    if (pair.num != -oo) {
                        if (dp[i] < pair.num + 1) {
                            dp[i] = pair.num + 1;
                            prev[i] = pair.index;
                        }
                    }
                }
                low = -1;
                high = n;
                while (high - low > 1) {
                    int mid = (high + low) >>> 1;
                    if (b[mid] >= a[i] + d) {
                        high = mid;
                    } else {
                        low = mid;
                    }
                }
                if (high != n) {
                    TaskE.Pair pair = query(high, n);
                    if (pair.num != -oo) {
                        if (dp[i] < pair.num + 1) {
                            dp[i] = pair.num + 1;
                            prev[i] = pair.index;
                        }
                    }
                }
                low = -1;
                high = n;
                while (high - low > 1) {
                    int mid = (high + low) >>> 1;
                    if (b[mid] <= a[i]) {
                        low = mid;
                    } else {
                        high = mid;
                    }
                }
                update(low, dp[i], i);
            }
            int last = -1;
            for (int i = 0; i < n; ++i) {
                if (last == -1 || dp[last] < dp[i]) {
                    last = i;
                }
            }
            out.println(dp[last]);
            List<Integer> nums = new ArrayList<>(n);
            while (last != -1) {
                nums.add(last + 1);
                last = prev[last];
            }
            Collections.reverse(nums);
            for (int i = 0; i < nums.size(); ++i) {
                if (i != 0) out.print(" ");
                out.print(nums.get(i));
            }
            out.println();
        }

        public void build(int s, int e, int c) {
            if (s == e) {
                seg[c] = new TaskE.Pair(-oo, -1);
                return;
            }
            int m = (s + e) >>> 1;
            build(s, m, 2 * c + 1);
            build(m + 1, e, 2 * c + 2);
            seg[c] = merge(seg[2 * c + 1], seg[2 * c + 2]);
        }

        public void update(int index, int value, int pos) {
            update(0, n - 1, 0, index, value, pos);
        }

        public void update(int s, int e, int c, int index, int value, int pos) {
            if (s == e) {
                seg[c] = new TaskE.Pair(value, pos);
                return;
            }
            int m = (s + e) >>> 1;
            if (index <= m) {
                update(s, m, 2 * c + 1, index, value, pos);
            } else {
                update(m + 1, e, 2 * c + 2, index, value, pos);
            }
            seg[c] = merge(seg[2 * c + 1], seg[2 * c + 2]);
        }

        public TaskE.Pair query(int l, int r) {
            return query(0, n - 1, 0, l, r);
        }

        public TaskE.Pair query(int s, int e, int c, int l, int r) {
            if (l > r || s > e || s > r || e < l) return new TaskE.Pair(-oo, -1);
            if (s == e) {
                return seg[c];
            }
            if (s >= l && e <= r) {
                return seg[c];
            }
            int m = (s + e) >>> 1;
            return merge(query(s, m, 2 * c + 1, l, r), query(m + 1, e, 2 * c + 2, l, r));
        }

        public TaskE.Pair merge(TaskE.Pair left, TaskE.Pair right) {
            if (left == null) return right;
            if (right == null) return left;
            if (left.num > right.num) return left;
            else return right;
        }

        static class Pair {
            int num;
            int index;

            public Pair(int num, int index) {
                this.num = num;
                this.index = index;
            }

        }

    }

    static class FastReader {
        private InputStream stream;
        private byte[] buf = new byte[8192];
        private int curChar;
        private int pnumChars;
        private FastReader.SpaceCharFilter filter;

        public FastReader(InputStream stream) {
            this.stream = stream;
        }

        private int pread() {
            if (pnumChars == -1) {
                throw new InputMismatchException();
            }
            if (curChar >= pnumChars) {
                curChar = 0;
                try {
                    pnumChars = stream.read(buf);
                } catch (IOException e) {
                    throw new InputMismatchException();
                }
                if (pnumChars <= 0) {
                    return -1;
                }
            }
            return buf[curChar++];
        }

        public int nextInt() {
            int c = pread();
            while (isSpaceChar(c))
                c = pread();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = pread();
            }
            int res = 0;
            do {
                if (c == ',') {
                    c = pread();
                }
                if (c < '0' || c > '9') {
                    throw new InputMismatchException();
                }
                res *= 10;
                res += c - '0';
                c = pread();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public long nextLong() {
            int c = pread();
            while (isSpaceChar(c))
                c = pread();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = pread();
            }
            long res = 0;
            do {
                if (c < '0' || c > '9') {
                    throw new InputMismatchException();
                }
                res *= 10;
                res += c - '0';
                c = pread();
            } while (!isSpaceChar(c));
            return res * sgn;
        }

        public long[] nextLongArray(int n) {
            long[] array = new long[n];
            for (int i = 0; i < n; i++) {
                array[i] = nextLong();
            }
            return array;
        }

        private boolean isSpaceChar(int c) {
            if (filter != null) {
                return filter.isSpaceChar(c);
            }
            return isWhitespace(c);
        }

        private static boolean isWhitespace(int c) {
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

        private interface SpaceCharFilter {
            public boolean isSpaceChar(int ch);

        }

    }

    static class ArrayUtils {
        public static long[] sort(long[] a) {
            a = shuffle(a, new SplittableRandom());
            Arrays.sort(a);
            return a;
        }

        public static long[] shuffle(long[] a, SplittableRandom gen) {
            for (int i = 0, n = a.length; i < n; i++) {
                int ind = gen.nextInt(n - i) + i;
                long d = a[i];
                a[i] = a[ind];
                a[ind] = d;
            }
            return a;
        }

        public static void fill(int[] array, int value) {
            Arrays.fill(array, value);
        }

    }
}

