-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPresents.java
More file actions
26 lines (24 loc) · 796 Bytes
/
Presents.java
File metadata and controls
26 lines (24 loc) · 796 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
/**
* Created by MalhotR1 on 2/14/2017.
*/
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.IOException;
import java.util.HashMap;
import java.util.Map;
public class Presents {
public static void main(String[] args) throws IOException {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
int N = Integer.parseInt(br.readLine().trim());
String[] in = br.readLine().trim().split(" ");
int[] arr = new int[N];
Map<Integer, Integer> lookup = new HashMap<>();
for (int i = 0; i < N; i++) {
arr[i] = Integer.parseInt(in[i]);
lookup.put(arr[i], i+1);
}
for (int i = 1; i <= N; i++) {
System.out.print(lookup.get(i) + " ");
}
}
}