#include <bits/stdc++.h>
using namespace std;
#pragma GCC optimize("O3")
const int mod = (1e9) + 7;
const double eps = 1e-10;
const int siz = 1e5 + 5, siz2 = 18, siz3 = 5032108;
int n, l[1005], r[1005], pref[1005], suff[1005], ans[1005];
int fill(int v) {
  for (int i = 1; i <= n; i++) {
    pref[i] = (ans[i] != 0) + pref[i - 1];
  }
  for (int i = n; i >= 1; i--) {
    suff[i] = (ans[i] != 0) + suff[i + 1];
  }
  int tot = 0;
  for (int i = 1; i <= n; i++) {
    if (ans[i] == 0 && l[i] == pref[i - 1] && r[i] == suff[i + 1]) {
      ans[i] = v;
      tot++;
    }
  }
  return tot;
}
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &l[i]);
  }
  for (int i = 1; i <= n; i++) {
    scanf("%d", &r[i]);
  }
  int cur = n, tot = 0;
  while (tot < n) {
    int filled = fill(cur);
    if (filled == 0) {
      printf("NO\n");
      return 0;
    }
    tot += filled;
    cur--;
  }
  printf("YES\n");
  for (int i = 1; i <= n; i++) {
    printf("%d ", ans[i]);
  }
  printf("\n");
  return 0;
}
