N = int(input())

a = list(map(int, input().split()))



dict = {}

for i in range(len(a)):

  dict[a[i]] = i+1



for i in range(len(dict)):

  print(dict[i+1], end =" ")

N = int(eval(input()))

A = list(map(int, input().split()))



ans = [0]*N

for i in range(N):

  ans[A[i]-1] = str(i+1)

  

print((" ".join(ans)))
N = int(input())
a = list(map(int, input().split()))
dict = {}
for i in range(len(a)):
    dict[a[i]] = i + 1
for i in range(len(dict)):
    print(dict[i + 1], end=" ")

N = int(eval(input()))
A = list(map(int, input().split()))
ans = [0] * N
for i in range(N):
    ans[A[i] - 1] = str(i + 1)
print((" ".join(ans)))

-N = int(input()) -a = list(map(int, input().split())) -dict = {} -for i in range(len(a)): -    dict[a[i]] = i + 1 -for i in range(len(dict)): -    print(dict[i + 1], end=" ") +N = int(eval(input())) +A = list(map(int, input().split())) +ans = [0] * N +for i in range(N): +    ans[A[i] - 1] = str(i + 1) +print((" ".join(ans)))