#include <bits/stdc++.h>
int o[100010];
int s[100010];
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 0; i < n; i++) scanf("%d", &o[i]);
  for (int i = 0; i < n; i++) scanf("%d", &s[o[i] - 1]);
  for (int i = 0; i < n; i++) printf("%d ", s[i]);
  printf("\n");
  return 0;
}
