#include <bits/stdc++.h>
using namespace std;
bool closed[1000011];
int n, t;
int p[1000011];
int q[1000011];
stack<int> second;
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) scanf("%d", &p[i]);
  scanf("%d", &t);
  for (int i = 0; i < t; i++) scanf("%d", &q[i]), q[i]--, closed[q[i]] = 1;
  for (int i = n - 1; i >= 0; i--) {
    if (second.size() > 0 and p[second.top()] == p[i] and !closed[i]) {
      closed[second.top()] = 1;
      second.pop();
    } else {
      second.push(i);
      closed[i] = 1;
    }
  }
  if (second.size()) {
    printf("NO\n");
  } else {
    printf("YES\n");
    for (int i = 0; i < n; i++) printf("%d ", closed[i] ? -p[i] : p[i]);
  }
}
