#include <bits/stdc++.h>
using namespace std;
char buf[1 << 23], *p1 = buf, *p2 = buf;
int val[1000010], n, sta[1000010], top;
int read() {
  static int res;
  static char op;
  do
    op =
        (p1 == p2 && (p2 = (p1 = buf) + fread(buf, 1, 1 << 23, stdin), p1 == p2)
             ? EOF
             : *p1++);
  while (op > '9' || op < '0');
  for (res = 0; op >= '0' && op <= '9';
       op = (p1 == p2 &&
                     (p2 = (p1 = buf) + fread(buf, 1, 1 << 23, stdin), p1 == p2)
                 ? EOF
                 : *p1++))
    res = res * 10 + (op ^ 48);
  return res;
}
signed main(int argc, char **argv) {
  n = read();
  for (int i = 1; i <= n; ++i) val[i] = read();
  for (int i = 1, t = read(); i <= t; ++i) val[read()] *= -1;
  for (int i = n; i; --i)
    if (val[i] < 0)
      sta[++top] = val[i];
    else if (top && val[i] == -sta[top])
      --top;
    else
      val[i] *= -1, sta[++top] = val[i];
  if (top)
    puts("NO");
  else {
    puts("YES");
    for (int i = 1; i <= n; ++i) printf("%d ", val[i]);
  }
  return 0;
}
