PROGRAMMING:Inverse hash problem
Given a hash table of length $$n $, the most common hash mapping for integer processing is $$H (x) = x \% n $. If we decide to use linear detection to solve the conflict problem, we can easily get the distribution of these integers in the hash table given a sequence of integers. For example, after inserting 1, 2, and 3 into the hash table 'HT [] with length of 3, we will get the results of' HT [0] = 3 ','ht [1] = 1','ht [2] = 2 '.
But now we need to solve the "inverse hash problem", that is, given the distribution of integers in the hash table, what is the order in which these integers are inserted?
###Input format:
The first line of the input is the positive integer n ($$$Le $$1000), which is the length of the hash table. The second line gives n integers separated by spaces. The position of each integer in the sequence (the first number position is 0) is its position in the hash table, where a negative number means that there is no element in the table. The nonnegative integers in the title guarantee table are different.
###Output format:
Output these integers in the order of insertion, separated by spaces, and there should be no extra spaces at the beginning and end of the line. Note: for the same distribution result, the insertion order may not be unique. For example, if we insert a hash table of length 3 in order of 3, 2, and 1, we will get the same result as inserting it in order of 1, 2, and 3. It is stipulated here that when there are multiple choices for the current insertion, the minimum number must be selected, so as to ensure the uniqueness of the final output result.
###Input example:
```in
eleven
33 1 13 12 34 38 27 22 32 -1 21
```
###Output example:
```out
1 13 12 21 33 34 38 27 22 32
```
answer:If there is no answer, please comment
But now we need to solve the "inverse hash problem", that is, given the distribution of integers in the hash table, what is the order in which these integers are inserted?
###Input format:
The first line of the input is the positive integer n ($$$Le $$1000), which is the length of the hash table. The second line gives n integers separated by spaces. The position of each integer in the sequence (the first number position is 0) is its position in the hash table, where a negative number means that there is no element in the table. The nonnegative integers in the title guarantee table are different.
###Output format:
Output these integers in the order of insertion, separated by spaces, and there should be no extra spaces at the beginning and end of the line. Note: for the same distribution result, the insertion order may not be unique. For example, if we insert a hash table of length 3 in order of 3, 2, and 1, we will get the same result as inserting it in order of 1, 2, and 3. It is stipulated here that when there are multiple choices for the current insertion, the minimum number must be selected, so as to ensure the uniqueness of the final output result.
###Input example:
```in
eleven
33 1 13 12 34 38 27 22 32 -1 21
```
###Output example:
```out
1 13 12 21 33 34 38 27 22 32
```
answer:If there is no answer, please comment