#include <bits/stdc++.h>
using namespace std;
long long int n, a[1000005], m;
stack<long long int> s;
int main() {
  scanf("%lld", &n);
  for (int i = 1; i <= n; i++) scanf("%lld", &a[i]);
  scanf("%lld", &m);
  for (int i = 0, x; i < m; i++) scanf("%d", &x), a[x] *= -1;
  for (int i = n; i >= 1; i--) {
    if (s.size() == 0 || s.top() != a[i])
      s.push(abs(a[i])), a[i] = -1 * s.top();
    else
      s.pop();
  }
  if (s.size()) return printf("NO\n"), 0;
  printf("YES\n");
  for (int i = 1; i <= n; i++) printf("%lld ", a[i]);
  printf("\n");
  return 0;
}
