#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  long long n = 0;
  cin >> n;
  vector<long long> p(n);
  for (long long i = 0; i < n; i++) {
    cin >> p[i];
  }
  long long t;
  cin >> t;
  for (long long i = 0; i < t; i++) {
    long long tmp;
    cin >> tmp;
    tmp--;
    p[tmp] *= -1;
  }
  map<long long, long long> m;
  for (long long i = 0; i < n; i++) {
    if (p[i] > 0)
      m[p[i]]++;
    else
      m[-p[i]]--;
  }
  for (typeof((m).begin()) pr = (m).begin(); pr != (m).end(); pr++) {
    if (pr->second % 2) {
      cout << "NO" << endl;
      return 0;
    }
  }
  stack<long long> st;
  for (long long i = n - 1; i >= 0; i--) {
    if (p[i] > 0) {
      if (st.empty() || st.top() != p[i]) {
        p[i] *= -1;
        st.push(-p[i]);
      } else {
        st.pop();
      }
    } else
      st.push(-p[i]);
  }
  if (!st.empty()) {
    cout << "NO" << endl;
    return 0;
  }
  cout << "YES" << endl;
  for (long long i = 0; i < n; i++) {
    cout << p[i] << " ";
  }
  cout << endl;
}
