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:
/**
 * Practiced on 12/27/2014
 * 
 * http://codeforces.com/contest/379/problem/C
 */

//package com.congli.codeforces;

import java.io.BufferedReader;
import java.io.FileReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.PrintWriter;
import java.util.Arrays;
import java.util.Locale;
import java.util.StringTokenizer;

public class Goodbye2013A_NewYearRatingsChange {

  BufferedReader in;
  PrintWriter out;
  StringTokenizer tok = new StringTokenizer("");
  
  public static void main(String[] args) {
    Goodbye2013A_NewYearRatingsChange test = new Goodbye2013A_NewYearRatingsChange();
    test.start();
  }

  public void solve() throws IOException {
    int n = readInt();
    Item[] array = new Item[n];
    
    for (int i = 0; i < n; ++i) {
      array[i] = new Item(readInt());
    }
    
    Item[] copy = array.clone();
    Arrays.sort(copy);
    
    int rating = 0;
    for (int i = 0; i < n; ++i) {
      if (rating < copy[i].a) {
        rating = copy[i].a;
      }
      copy[i].b = rating;
      ++rating;
    }
    
    for (int i = 0; i < n-1; ++i) {
      out.print(array[i].b + " ");
    }
    out.println(array[n-1].b);
  }

  public void start() {
    try {
      long t1 = System.currentTimeMillis();
      if (System.getProperty("ONLINE_JUDGE") != null) {
        in = new BufferedReader(new InputStreamReader(System.in));
        out = new PrintWriter(System.out);
      } else {
        in = new BufferedReader(new FileReader("/Users/congli/Documents/javaworkspace/codeforces/src/com/congli/codeforces/input.txt"));
        out = new PrintWriter(System.out);
      }
      Locale.setDefault(Locale.US);
      solve();
      in.close();
      out.close();
      long t2 = System.currentTimeMillis();
      System.err.println("Time = " + (t2 - t1));
    } catch (Throwable t) {
      t.printStackTrace(System.err);
      System.exit(-1);
    }
  }
  
  public String readString() throws IOException {
    while (!tok.hasMoreTokens()) {
      tok = new StringTokenizer(in.readLine());
    }
    return tok.nextToken();
  }

  public int readInt() throws IOException {
    return Integer.parseInt(readString());
  }

  public long readLong() throws IOException {
    return Long.parseLong(readString());
  }

  public double readDouble() throws IOException {
    return Double.parseDouble(readString());
  }
  
  class Item implements Comparable<Item> {
    int a;
    int b;
    public Item(int a) {
      this.a = a;
      b = 0;;
    }
    
    @Override
    public int compareTo(Item o) {
      return this.a - o.a;
    }
  }
}