#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int _ = 1;
  while (_--) {
    int n;
    cin >> n;
    vector<int> a;
    string s;
    bool ok = true;
    int bal = 0;
    for (int i = 0; i < 2 * n; i++) {
      char c;
      cin >> c;
      s += c;
      if (s[i] == '+') {
        bal++;
      } else {
        bal--;
      }
      if (bal < 0) {
        ok = false;
      }
      if (c == '-') {
        int x;
        cin >> x;
        a.push_back(x);
      }
    }
    if (!ok || bal != 0) {
      cout << "NO" << endl;
      continue;
    }
    int it = n - 1;
    stack<int> st;
    vector<int> b;
    for (int i = 2 * n - 1; i >= 0; i--) {
      if (s[i] == '-') {
        st.push(a[it--]);
      } else {
        b.push_back(st.top());
        st.pop();
      }
    }
    reverse(b.begin(), b.end());
    set<int> c;
    int x = 0, y = 0;
    for (int i = 0; i < 2 * n; i++) {
      if (s[i] == '+') {
        c.insert(b[x++]);
      } else {
        if (*c.begin() != a[y++]) {
          ok = false;
          break;
        }
        c.erase(c.begin());
      }
    }
    cout << (ok ? "YES" : "NO") << endl;
    if (ok) {
      for (int i : b) {
        cout << i << " ";
      }
      cout << endl;
    }
  }
}
