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.ArrayList;
import java.util.Arrays;
import java.util.Collections;
import java.util.HashMap;
import java.util.PriorityQueue;
import java.util.Random;
import java.util.StringTokenizer;
import java.util.stream.LongStream;

public class Solution{
	
	
    public static void main(String[] args) throws IOException {
    	
		
    	FastScanner fs = new FastScanner();
    	PrintWriter out = new PrintWriter(System.out);
    		
    	int tt = 1;
    	while(tt-->0) {
    		
    		
    		int n = fs.nextInt();
    		long d = fs.nextLong();
    		
    		long[] h = new long[n];
    		
    		for(int i=0;i<n;i++) h[i] = fs.nextLong();
    		
    		Data[] arr = new Data[n];
    		
    		for(int i=0;i<n;i++) {
    			arr[i] = new Data(h[i], i); 
    		}
    		
    		Arrays.sort(arr);
    		
    		
    		
    		SegTree tree = new SegTree(n);
    		int[] pre = new int[n];
    		
    		
    		
    		for(int i=0;i<n;i++) {
    			long l = h[i]-d, r = h[i]+d;
    			int ind1 = lowerbound(arr, new Data(l+1, 0))-1, ind2 = lowerbound(arr, new Data(r, 0));
    			int ind = lowerbound(arr, new Data(h[i], i));
    			int ans = 0;
    			Data t = new Data(0, 0);
    			if(ind1>=0) t = tree.maxquery(0, ind1);
    			if(ind2<n) t = max(t, tree.maxquery(ind2, n-1));
    			tree.updateTree(ind, new Data(t.val + 1, i));
    			pre[i] = t.ind;
    			tree.updateTree(ind, new Data(1, i));
    		}
    		
    		Data t = tree.maxquery(0, n-1);
    		int ans = (int) t.val;
    		int ind = t.ind;
    		
    		ArrayList<Integer> list = new ArrayList<>();
    		
    		int max = ans;
    		
    		while(max-->0) {
    			list.add(ind+1);
    			ind = pre[ind];
    		}
    		
    		out.println(ans);
    		
    		for(int j=list.size()-1;j>=0;j--) {
    			out.print(list.get(j)+" ");
    		}
    		out.println();
    		
    		
    		
    		
    		
    		
    		
    		
    		
    		
    		
    		
    	
    		
    		
    		
    	}
    	
    	out.close();
    		
    }
    
    
    
    static class Data implements Comparable<Data>{
    	long val;
    	int ind;
    	
    	Data(long val, int ind){
    		this.val = val;
    		this.ind = ind;
    	}

		@Override
		public int compareTo(Data o) {
			if(this.val==o.val) return this.ind-o.ind;
			return Long.compare(this.val, o.val);
		}
    	
    }
    		
    
    
    static int lowerbound(Data[] arr, Data d) {
    	int l = 0, r = arr.length;
    	while(l<r) {
    		int mid = (l+r)/2;
    		if(arr[mid].compareTo(d)<0) {
    			l = mid + 1;
    		}
    		else {
    			r = mid;
    		}
    	}
    	return l;
    }
    
    
    
    
    
    static class SegTree{
    	Data[] tree;
    	int n;
    	
    	SegTree(int n){
    		tree = new Data[4*n];
    		for(int i=0;i<4*n;i++) {
    			tree[i] = new Data(0, 0);
    		}
    		this.n = n;
    	}
    	
    	
    	Data maxquery(int qs, int qe) {
    		return query(qs, qe, 0, n-1, 0);
    	}
    	
    	Data query(int qs, int qe, int ns, int ne, int node) {
    		if(ne<qs || ns>qe) return new Data(0, 0);
    		if(ns>=qs && ne<=qe) return tree[node];
    		int mid = (ns+ne)/2;
    		return max(query(qs, qe, ns, mid, 2*node+1), query(qs, qe, mid+1, ne, 2*node+2)); 
    	}
    	
    	void updateTree(int ind,Data val) {
    		update(ind, val, 0, n-1, 0);
    	}
    	
    	void update(int ind, Data val, int ns, int ne, int node) {
    		if(ind<ns || ind>ne) return;
    		if(ns==ne) {
    			tree[node] = max(tree[node], val); 
    			return;
    		}
    		int mid = (ns+ne)/2;
    		update(ind, val, ns, mid, 2*node+1);
    		update(ind, val, mid+1, ne, 2*node+2);
    		tree[node] = max(tree[2*node+1], tree[2*node+2]);
    	}
    	
    	
    }
    
    
    
    static Data max(Data d1, Data d2) {
    	if(d1.compareTo(d2)>0) return d1;
    	return d2;
    }
    
    
    
    
    
    static final Random random=new Random();
    
    static <T> void shuffle(T[] arr) {
    	int n = arr.length;
    	for(int i=0;i<n;i++	) {
    		int k = random.nextInt(n);
    		T temp = arr[k]; arr[k] = arr[i]; arr[i] = temp;
    	}
    }
    
    	
    static void ruffleSort(int[] a) {
    	int n=a.length;//shuffle, then sort 
    	for (int i=0; i<n; i++) {
    		int oi=random.nextInt(n); int temp=a[oi];
    		a[oi]=a[i]; a[i]=temp;
    	}
    	Arrays.sort(a);
    }
    
    static void ruffleSort(long[] a) {
    	int n=a.length;//shuffle, then sort 
    	for (int i=0; i<n; i++) {
    		int oi=random.nextInt(n); long temp=a[oi];
    		a[oi]=a[i]; a[i]=temp;
    	}
    	Arrays.sort(a);
    }
   
  
    
    static void reverse(int[] arr, int l, int r) {
    	for(int i=l;i<l+(r-l)/2;i++){
    		int temp = arr[i]; arr[i] = arr[r-i+l-1]; arr[r-i+l-1] = temp;
    	}
    }
    
    static void reverse(long[] arr, int l, int r) {
    	for(int i=l;i<l+(r-l)/2;i++){
    		long temp = arr[i]; arr[i] = arr[r-i+l-1]; arr[r-i+l-1] = temp;
    	}
    }
    
    
    static <T> void reverse(T[] arr, int l, int r) {
    	for(int i=l;i<l+(r-l)/2;i++) {
    		T temp = arr[i]; arr[i] = arr[r-i+l-1]; arr[r-i+l-1] = temp;
    	}
    }
    	
    	
    static class FastScanner{
    	BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
    	StringTokenizer st = new StringTokenizer("");
     
    	public String next(){
    		while(!st.hasMoreElements()){
    			try{
    				st = new StringTokenizer(br.readLine());
    			} catch(IOException e){
    				e.printStackTrace();
    			}
    		}
    		return st.nextToken();
    	}
    		
    	public String nextLine() throws IOException {
    		return br.readLine();
    	}
    		
    	public int nextInt(){
    		return Integer.parseInt(next());
    	}
     
    	public int[] readArray(int n){
    		int[] a = new int[n];
    		for(int i=0;i<n;i++)
    			a[i] = nextInt();
    		return a;
    	}
    		
    	public long nextLong() {
    		return Long.parseLong(next());
    	}
    		
    	public char nextChar() {
    		return next().toCharArray()[0];
    	}
    }
   	
}
