4305: 最简单的离散化

Memory Limit:128 MB Time Limit:1 S
Judge Style:Text Compare Creator:
Submit:247 Solved:113

Description

在使用离散化方法编程时,通常要知道每个数排序后的编号(rank值)。数据保证没有相同的数字。

Input

第1行:一个整数N,范围在[1…10000]。 第2行:有N个整数,每个数都是int范围的。

Output

依次输出每个数的排名。

Sample Input Copy

5
8 2 6 9 3

Sample Output Copy

4 1 3 5 2

Source/Category

加入题单

算法标签: