#include <bits/stdc++.h>
using namespace std;
vector<int> V[1000005];
pair<pair<int, int>, int> p[1000005];
bool sortBySecond(pair<pair<int, int>, int> A, pair<pair<int, int>, int> B) {
  return A.second < B.second;
}
int main() {
  int n, i, j, q;
  scanf("%d", &n);
  for (i = 0; i < n; i++) {
    p[i].first.first = i;
    p[i].first.second = i;
    scanf("%d", &p[i].second);
  }
  sort(p, p + n, sortBySecond);
  i = 0;
  p[i].first.second = 0;
  for (i = 1; i < n; i++) {
    p[i].first.second = p[i - 1].first.second;
    if (p[i].second != p[i - 1].second) p[i].first.second++;
  }
  sort(p, p + n);
  int t;
  scanf("%d", &t);
  for (i = 0; i < t; i++) {
    scanf("%d", &q);
    p[q - 1].second = -p[q - 1].second;
  }
  int current = 0;
  for (i = n - 1; i >= 0; i--) {
    if (V[p[i].first.second].size() > 0 &&
        V[p[i].first.second][V[p[i].first.second].size() - 1] + 1 == current &&
        p[i].second >= 0) {
      V[p[i].first.second].pop_back();
      current--;
    } else {
      V[p[i].first.second].push_back(current);
      current++;
      if (p[i].second > 0) p[i].second = -p[i].second;
    }
  }
  if (current > 0) {
    printf("NO");
  } else {
    printf("YES\n");
    for (i = 0; i < n; i++) {
      printf("%d ", p[i].second);
    }
  }
  return 0;
}
