#include <bits/stdc++.h>
using namespace std;
int n, m, a[1000005], cnt[1000005], s[1000005];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  scanf("%d", &m);
  for (int i = 1, x; i <= m; i++) scanf("%d", &x), a[x] *= -1;
  for (int i = n; i >= 1; i--)
    if (a[i] < 0)
      s[++s[0]] = a[i];
    else {
      if (s[0] && a[i] == -s[s[0]])
        s[0]--;
      else
        a[i] *= -1, s[++s[0]] = a[i];
    }
  if (s[0])
    puts("NO");
  else {
    puts("YES");
    for (int i = 1; i <= n; i++) printf("%d ", a[i]);
    puts("");
  }
  return 0;
}
