#include <bits/stdc++.h>
using namespace std;
const int N = 1e6 + 5;
int in[N];
bool t[N];
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; ++i) scanf("%d", in + i);
  int q;
  scanf("%d", &q);
  while (q--) {
    int a;
    scanf("%d", &a);
    t[a] = 1;
  }
  stack<int> stk;
  for (int i = n; i >= 1; i--) {
    if (t[i]) {
      stk.emplace(in[i]);
      in[i] = -in[i];
    } else {
      if (stk.empty() or stk.top() != in[i]) {
        stk.emplace(in[i]);
        in[i] = -in[i];
      } else {
        stk.pop();
      }
    }
  }
  if (!stk.empty()) return !printf("NO\n");
  puts("YES");
  for (int i = 1; i <= n; ++i) printf("%d ", in[i]);
}
