Let A = {a1, a2, ..., an} be any permutation of the first n natural numbers {1, 2, ..., n}. You are given a positive integer k and another sequence B = {b1, b2, ..., bn}, where bi is the number of elements aj in A to the left of the element at = i such that aj ≥ (i + k).

For example, if n = 5, a possible A is {5, 1, 4, 2, 3}. For k = 2, B is given by {1, 2, 1, 0, 0}. But if k = 3, then B = {1, 1, 0, 0, 0}.

For two sequences X = {x1, x2, ..., xn} and Y = {y1, y2, ..., yn}, let i-th elements be the first elements such that xi ≠ yi. If xi < yi, then X is lexicographically smaller than Y, while if xi > yi, then X is lexicographically greater than Y.

Given n, k and B, you need to determine the lexicographically smallest A.

Input

The first line contains two space separated integers n and k (1 ≤ n ≤ 1000, 1 ≤ k ≤ n). On the second line are n integers specifying the values of B = {b1, b2, ..., bn}.

Output

Print on a single line n integers of A = {a1, a2, ..., an} such that A is lexicographically minimal. It is guaranteed that the solution exists.

Examples

Input

5 2
1 2 1 0 0


Output

4 1 5 2 3 

Input

4 2
1 0 0 0


Output

2 3 1 4 
import java.io.*;
import java.util.*;
import static java.lang.System.*;
import static java.lang.Math.*;
/**
 * Restoration of Permutation -> Codeforces 
 * Link: https://codeforces.com/problemset/problem/67/B
 */
public class ROP
{
    void run() {
        int tc=1;
        StringBuilder sb = new StringBuilder();
        while(tc-->0) {
            int n=ni(),k=ni(),b[]=new int[n+1],K[]=new int[n+1];
            boolean vis[] = new boolean[n+1];
            TreeSet<Integer> set = new TreeSet<>();
            // List<Integer> list = new ArrayList<>();
            for(int i=1;i<=n;i++) {
            	b[i]=ni();
            	K[i]=k+i;
            }
            // out.println(Arrays.toString(K));
            int itr=0;
            while(set.size()<n) {
            	for(int i=1;i<=n;i++) {
            		itr++;
            		if(!vis[i]) {
            			Integer c = set.higher(K[i]);
                        c = K[i]<=n && vis[K[i]] ? new Integer(K[i]) : c;
            			if(c!=null) {
            				if(set.size()-set.headSet(c).size()==b[i]) {
            					set.add(i);
                                sb.append(i).append(" ");
                                vis[i]=true;
            					break;
            				}
            			}
            			else if(b[i]==0) {
                                set.add(i);
                                sb.append(i).append(" ");
                                vis[i]=true;
                				break;
            			}
                        // out.println(i+" "+set.headSet(c).size());
            		}
            	}
            	// try {
	            // 	if(itr>20) throw new Exception("Hold on Sparky!");
	            // } catch(Exception e) { out.println(e); break; }
            }
            // out.println(list);
            // for(int i=0;i<n;i++) sb.append(list.get(i)).append(" ");
        }
        out.println(sb);
        out.flush(); 
        out.close();
    }

    public static void main(String[] args)throws Exception {
        try { 
            // new Thread(null, new ROP()::run, "1", 1 << 26).start();
            new Thread(null, new ROP("ONLINE_JUDGE")::run, "1", 1 << 26).start();
        } catch(Exception e) {}
    }

    FastReader sc=null;PrintWriter out = null;
    public ROP()throws Exception {
        sc = new FastReader(new FileInputStream("input.txt"));
        out = new PrintWriter(new BufferedWriter(new FileWriter("output.txt")));
    }
    public ROP(String JUDGE) {
        sc = new FastReader(System.in);
        out = new PrintWriter(System.out);      
    }
    
    String ns() { return sc.next(); }
    int ni() { return sc.nextInt(); }
    long nl() { return sc.nextLong(); }
    int[] ni(int n) {
        int a[]=new int[n];
        for(int i=0;i<n;a[i++]=ni());
        return a;
    }
    long[] nl(int n) {
        long a[]=new long[n];
        for(int i=0;i<n;a[i++]=nl());
        return a;
    }
    
    int[][] ni(int n,int m) {
        int a[][]=new int[n][m];
        for(int i=0;i<n;i++) 
            for(int j=0;j<m;j++)
                a[i][j]=ni();
        return a;
    }
    long[][] nl(int n,int m) {
        long a[][]=new long[n][m];
        for(int i=0;i<n;i++) 
            for(int j=0;j<m;j++)
                a[i][j]=nl();
        return a;
    }
    int gcd(int a, int b) {
        return b==0?a:gcd(b,a%b);
    }
    static class FastReader {
        private InputStream stream;
        private byte[] buf = new byte[1024];
        private int curChar;
        private int numChars;
        private FastReader.SpaceCharFilter filter;
        public FastReader(InputStream stream) {
            this.stream = stream;
        }

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

        public int nextInt() {
            int c = read();
            while (isSpaceChar(c)) c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            int res = 0;
            do {
                if (c < '0' || c > '9') throw new InputMismatchException();
                res *= 10;
                res += c - '0';
                c = read();
            }
            while (!isSpaceChar(c));
            return res * sgn;
        }
        
        public long nextLong() {
            int c = read();
            while (isSpaceChar(c)) c = read();
            int sgn = 1;
            if (c == '-') {
                sgn = -1;
                c = read();
            }
            long res = 0;
            do {
                if (c < '0' || c > '9') throw new InputMismatchException();
                res = res*1L*10;
                res += c - '0';
                c = read();
            }
            while (!isSpaceChar(c));
            return res *1L* sgn;
        }
        
        public String next() {
            int c = read();
            while (isSpaceChar(c)) c = read();
            StringBuilder res = new StringBuilder();
            do {
                res.appendCodePoint(c);
                c = read();
            } while (!isSpaceChar(c));
            return res.toString();
        }

        public boolean isSpaceChar(int c) {
            if (filter != null) return filter.isSpaceChar(c);
            return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
        }

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

        }
    }
}