n = int(input())

a = [int(i) for i in input().split()]

dic={}

for i in range(n):

	dic[i]=a[i]

dic = sorted(dic.items(), key=lambda x:x[1])

for i in dic:

	print(i[0]+1,end=' ')

n = int(input())

a = [int(i) for i in input().split()]

box = [0]*n

for i in range(n):

	box[a[i]-1] = i+1

for i in box:

	print(i,end=' ')

n = int(input())
a = [int(i) for i in input().split()]
dic = {}
for i in range(n):
    dic[i] = a[i]
dic = sorted(dic.items(), key=lambda x: x[1])
for i in dic:
    print(i[0] + 1, end=" ")

n = int(input())
a = [int(i) for i in input().split()]
box = [0] * n
for i in range(n):
    box[a[i] - 1] = i + 1
for i in box:
    print(i, end=" ")

-dic = {} +box = [0] * n -    dic[i] = a[i] -dic = sorted(dic.items(), key=lambda x: x[1]) -for i in dic: -    print(i[0] + 1, end=" ") +    box[a[i] - 1] = i + 1 +for i in box: +    print(i, end=" ")