#include <bits/stdc++.h>
using namespace std;
long long read() {
  long long x = 0, f = 1;
  char ch = getchar();
  while (ch < '0' || ch > '9') {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  while (ch >= '0' && ch <= '9') {
    x = x * 10 + ch - '0';
    ch = getchar();
  }
  return x * f;
}
int n, t, p[1000050], ans[1000050];
bool mark[1000050];
struct data {
  int a, id;
} sta[1000050];
int main() {
  n = read();
  for (int i = 1; i <= n; i++) p[i] = read();
  t = read();
  for (int i = 1; i <= t; i++) mark[read()] = 1;
  int w = 0;
  for (int i = n; i >= 1; i--) {
    if (w == 0 || mark[i] || p[i] != sta[w - 1].a)
      sta[w++] = (data){p[i], i};
    else
      ans[i] = p[i], ans[sta[--w].id] = -p[i];
  }
  if (w) {
    printf("NO");
    return 0;
  }
  printf("YES\n");
  for (int i = 1; i <= n; i++) {
    if (i != 1) printf(" ");
    printf("%d", ans[i]);
  }
  return 0;
}
