Problem: One very well-known internet resource site (let's call it X) has come up with a New Year adventure. Specifically, they decided to give ratings to all visitors.

There are n users on the site, for each user we know the rating value he wants to get as a New Year Present. We know that user i wants to get at least ai rating units as a present.

The X site is administered by very creative and thrifty people. On the one hand, they want to give distinct ratings and on the other hand, the total sum of the ratings in the present must be as small as possible.

Help site X cope with the challenging task of rating distribution. Find the optimal distribution.

Input

The first line contains integer n (1 ≤ n ≤ 3·105) — the number of users on the site. The next line contains integer sequence a1, a2, ..., an (1 ≤ ai ≤ 109).

Output

Print a sequence of integers b1, b2, ..., bn. Number bi means that user i gets bi of rating as a present. The printed sequence must meet the problem conditions. 

If there are multiple optimal solutions, print any of them.

Examples

Input

3
5 1 1


Output

5 1 2


Input

1
1000000000


Output

1000000000

Solution (in JAVA):

Solution:
import java.io.*;
import java.io.PrintWriter;
import java.util.*;
import java.io.InputStream;
import java.io.DataInputStream;
 
 
 
public class Main
{//static{ System.out.println("hello");}
    static byte[] buffer = new byte[8192];
    static int offset = 0;
    static int bufferSize = 0;
    static void print(char a[])
    {for (int i=0;i<a.length ;i++)
        {
         System.out.print(a[i]+"");   
           }   
   }   
 
        public static void main(String[] args) throws IOException
       { InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        FastReader scn = new FastReader(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
          int n=scn.ni();
          ArrayList<num> arr=new ArrayList<num>();
          for (int i=1;i<=n;i++)
          {
            arr.add(new num(scn.ni(),i));   
              
            }    
            Collections.sort(arr,new Comparator<num>()
            {   public int compare(num n1, num n2)
                    {   if (n1.a!=n2.a) return n1.a-n2.a;
                           else return n1.b-n2.b;
               
                    }   
            
            }
            );
            
            for (int i=1;i<arr.size();i++)
            { 
                if ( arr.get(i-1).a +1 < arr.get(i).a ) continue;
                else
                 arr.get(i).a=arr.get(i-1).a+1;
            }
            
             Collections.sort(arr,new Comparator<num>()
            {   public int compare(num n1, num n2)
                    {   if (n1.b!=n2.b) return n1.b-n2.b;
                           else return n1.a-n2.a;
               
                    }   
            
            }
            );
            
             for (int i=0;i<arr.size();i++)  out.print(arr.get(i).a+" ");
             
             out.close();
        }     
  
                    
         
}

class num 
{ public int a;
    public int b;
    num() { }
    num(int x, int y)
    {  a=x; 
       b=y;   
    }    
    
  
}  

class FastReader
{
 
    public InputStream stream;
    private byte[] buf = new byte[1024];
    private int curChar;
    private int numChars;
    private 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 char nc()
    {
        int c = read ();
        while (isSpaceChar (c))
            c = read ();
        return (char) c;
    }
    
    public int ni()
    {
        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')
            {
 
                
            }
            res *= 10;
            res += c - '0';
            c = read ();
        } while (!isSpaceChar (c));
        return res * sgn;
    }
 
    public long nl()
    {
        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 *= 10;
            res += c - '0';
            c = read ();
        } while (!isSpaceChar (c));
        return res * sgn;
    }
 
    public String ns()
    {
        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 isWhitespace (c);
    }
 
    public static boolean isWhitespace(int c)
    {
        return c==' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
    }
 
    public String next()
    {
        return ns ();
    }
 
    public interface SpaceCharFilter
    {
        public boolean isSpaceChar(int ch);
    }
}