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.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.StringTokenizer;

public class E474 {
    
    BufferedReader br;
    StringTokenizer in;
    PrintWriter out;
    
    public String nextToken() throws IOException {
        while (in == null || !in.hasMoreTokens()) {
            in = new StringTokenizer(br.readLine());
        }
        return in.nextToken();
    }

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

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

    public double nextDouble() throws IOException {
        return Double.parseDouble(nextToken());
    }
    
    public void solve() throws IOException {
        br = new BufferedReader(new InputStreamReader(System.in));
        out = new PrintWriter(System.out);
        
        int n = nextInt();
        int d = nextInt();
        
        long [] h = new long[n+1];
        TreePair[] pairs = new TreePair[n+1];
        
        for(int i = 1 ; i<=n ; i++) {
            h[i] = nextLong();
            pairs[i] = new TreePair(h[i],i);
        }
        
        Arrays.sort(pairs,1 , n+1);
        
        int [] newPos = new int[n+1];
        for(int i = 1 ; i <= n ; i++) {
            newPos[pairs[i].index] = i;
        }
        
        int [] results = new int[n+1];
        int [] prev = new int[n+1];
        int max = -1;
        int index = -1;
        results[1] = 1;
        prev[1] = -1;
        STree st = new STree(n);
        for(int i = 1 ; i < results.length ; i++) {
            results[i] = 1;
            
            long lowerBound = h[i] - d;
            long upperBound = h[i] + d;
            
            int index1 = binaryUpper(pairs,lowerBound);
            int index2 = binaryLower(pairs,upperBound);
            int v1 = 0; 
            int v2 = 0;
            if(index1 != -1)
                v1 = st.query(1, 1, n, 1, index1);
            if(index2 != -1)
                v2 = st.query(1, 1, n, index2, n);
            
            if(st.getValue(v1) > st.getValue(v2)) {
                results[i] = st.getValue(v1)+1;
                prev[i] = v1;
            }else {
                results[i] = st.getValue(v2)+1;             
                prev[i] = v2;
            }
            
            st.update(1, 1, n, newPos[i], results[i]);
            if(results[i] >= max) {
                max = results[i];
                index = i;
            }
        }
        System.out.println(max);
        int [] print = new int[max+1];
        print[max] = index;
        max--;
        for(int i = index-1; i > 0; i--) {
            if(results[i] + 1 == results[index] && Math.abs(h[i] - h[index]) >= d) {
                print[max] = i;
                index = i;
                max--;
            }
        }
        for(int i = 1 ; i <print.length ;i++)
            System.out.print(print[i]+" ");
    }
    
   public static int binaryLower(TreePair pairs[], long target) {
        int lower = 1, upper = pairs.length-1;
        while (lower < upper) {
            int mid = (lower+upper) / 2;
            if (pairs[mid].value < target)
                lower = mid + 1;
            else
                upper = mid;
        }
        if (pairs[upper].value >= target)
            return upper;
        return -1;
    }

   public static int binaryUpper(TreePair pairs[], long target) {
        int lower = 1, upper = pairs.length-1;
        while (lower < upper) {
            int mid = (lower+upper+1) / 2;
            if (pairs[mid].value > target)
                upper = mid - 1;
            else
                lower = mid;
        }
        if (pairs[lower].value <= target)
            return lower;
        return -1;
    }
    
    public static void main (String [] args) throws IOException {
        new E474().solve();
    }
}
class TreePair implements Comparable<TreePair>{

    long value;
    int index;
    
    public TreePair(long value, int index) {
        this.value = value;
        this.index = index;
    }
    
    @Override
    public int compareTo(TreePair o) {
        if(this.value < o.value)
            return -1;
        if(o.value < this.value)
            return 1;
        return this.index - o.index;
    }
    
}

class STree {
    int size;
    int[] values;
    int[] max;
    
    public STree(int size) {
        this.size = size;
        values = new int[size+1];
        max = new int[size<<2];
    }
    
    public int getValue(int index) {
        return this.values[index];
    }
    
    public int query (int nodeId, int lower, int upper, int queryLower, int queryUpper) {
        if(queryLower > upper || queryUpper < lower)
            return -1;
        
        if(queryLower <= lower && queryUpper >= upper)
            return max[nodeId];
        
        int nextNode = nodeId << 1;
        int mid = (lower + upper) / 2;
        
        int index1 = query(nextNode, lower, mid, queryLower, queryUpper);
        int index2 = query(nextNode|1, mid+1, upper, queryLower, queryUpper);
        
        if(index1 == -1)
            return index2;
        
        if(index2 == -1)
            return index1;
        
        if(values[index1] > values[index2])
            return index1;
        else
            return index2;
    }
    
    public void update(int nodeId, int lower, int upper, int index, int val) {
        if(index > upper || index < lower)
            return;
        
        if(lower == upper) {
            values[index] = val;
            max[nodeId] = index;
            return;
        }
        
        int nextNode = nodeId << 1;
        int mid = (lower + upper) / 2;
        
        update(nextNode, lower, mid, index, val);
        update(nextNode|1, mid + 1, upper, index, val);
        
        if (values[max[nextNode]] >= values[max[nextNode|1]])
            max[nodeId] = max[nextNode];
        else
            max[nodeId] = max[nextNode|1];
    }
}
