#include <bits/stdc++.h>
using namespace std;
map<int, int> hehe;
int main() {
  int n;
  scanf("%d", &n);
  hehe.clear();
  int x;
  for (int i = 1; i <= n; i++) {
    scanf("%d", &x);
    hehe[x] = i;
  }
  for (int i = 1; i <= n; i++) {
    scanf("%d", &x);
    printf("%d ", hehe[x]);
  }
  puts("");
  return 0;
}
