n = int(input()) a = list(map(int,input().split())) b = [] for ele in a: val = a[ a[ele-1]-1 ] b.append(val) print(*b)