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.
//package codeforces;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.*;

public class E {
    BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
    PrintWriter writer = new PrintWriter(System.out);
    StringTokenizer stringTokenizer;

    String next() throws IOException {
        while (stringTokenizer == null || !stringTokenizer.hasMoreTokens()) {
            stringTokenizer = new StringTokenizer(reader.readLine());
        }
        return stringTokenizer.nextToken();
    }

    int nextInt() throws IOException {
        return Integer.parseInt(next());
    }

    long nextLong() throws IOException {
        return Long.parseLong(next());
    }

    void solve() throws IOException {
        final int n = nextInt();
        int d = nextInt();
        long[] h = new long[n + 1];
        Long[] sortedTmp = new Long[n + 2];
        for (int i = 0; i < n; i++) {
            h[i + 1] = nextLong();
            sortedTmp[i] = h[i];
        }
        sortedTmp[n] = Long.MIN_VALUE;
        sortedTmp[n + 1] = Long.MAX_VALUE;
        Arrays.sort(sortedTmp);
        long[] sorted = new long[n + 2];
        for (int i = 0; i < sorted.length; i++) {
            sorted[i] = sortedTmp[i];
        }
        final int[] dp = new int[n + 1];
        final int[] prev = new int[n + 1];
        class Utils {
            int q = 1;
            int[] a;

            {
                while (q <= n + 2) q *= 2;
                a = new int[q * 2];
            }

            void add(int pos, int pillar) {
                for (pos += q; pos > 0; pos /= 2) {
                    if (dp[pillar] > dp[a[pos]]) {
                        a[pos] = pillar;
                    }
                }
            }

            int max(int l, int r) {
                int pillar = 0;
                for (l += q, r += q; l < r; l /= 2, r /= 2) {
                    if (l % 2 == 1) {
                        if (dp[a[l]] > dp[pillar]) {
                            pillar = a[l];
                        }
                        l++;
                    }
                    if (r % 2 == 1) {
                        --r;
                        if (dp[a[r]] > dp[pillar]) {
                            pillar = a[r];
                        }
                    }
                }
                return pillar;
            }
        }
        Utils utils = new Utils();
        h[0] = Long.MIN_VALUE;
        for (int i = 1; i <= n; i++) {
            long hl = h[i] - d;
            int lo = 0, hi = sorted.length - 1;
            while (hi - lo > 1) {
                int med = lo + hi >> 1;
                if (sorted[med] <= hl) {
                    lo = med;
                } else {
                    hi = med;
                }
            }
            int prevPillar = utils.max(0, lo + 1);
            if (dp[i] < dp[prevPillar] + 1) {
                dp[i] = dp[prevPillar] + 1;
                prev[i] = prevPillar;
            }

            long hr = h[i] + d;
            lo = 0;
            hi = sorted.length - 1;
            while (hi - lo > 1) {
                int med = lo + hi >> 1;
                if(sorted[med] >= hr) {
                    hi = med;
                } else {
                    lo = med;
                }
            }
            prevPillar = utils.max(hi, sorted.length);
            if(dp[i] < dp[prevPillar] + 1) {
                dp[i] = dp[prevPillar] + 1;
                prev[i] = prevPillar;
            }

            lo = 0;
            hi = sorted.length - 1;
            while(hi - lo > 1) {
                int med = lo + hi >> 1;
                if(sorted[med] >= h[i]) {
                    hi = med;
                } else {
                    lo = med;
                }
            }
            utils.add(hi, i);
        }
        int maxi = 0;
        for(int i = 1; i <= n; i++) {
            if(dp[i] > dp[maxi]) {
                maxi = i;
            }
        }
        int[] ans = new int[dp[maxi]];
        int j = ans.length;
        for(int i = maxi; i > 0; i = prev[i]) {
            ans[--j] = i;
        }
        writer.println(ans.length);
        for (int x : ans) {
            writer.printf("%d ", x);
        }
        writer.println();
        writer.close();
    }

    public static void main(String[] args) throws IOException {
        new E().solve();
    }
}


