#include <bits/stdc++.h>
using namespace std;
vector<int> v, used;
vector<vector<int> > q;
set<int> s;
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0), cout.tie(0);
  int n, x;
  cin >> n;
  v.assign(n, -1), used.assign(n, 0);
  char c;
  q.resize(2 * n);
  for (int i = 0; i < 2 * n; i++) {
    cin >> c;
    if (c == '+') {
      q[i] = {1};
    } else {
      cin >> x;
      x--;
      q[i] = {2, x};
    }
  }
  s.clear();
  int ind = n - 1;
  for (int i = 2 * n - 1; i >= 0; i--) {
    if (q[i][0] == 2) {
      s.insert(q[i][1]);
    } else {
      if ((int)(s).size() == 0) {
        cout << "NO\n";
        return 0;
      }
      auto it = s.begin();
      v[ind--] = *it;
      s.erase(it);
    }
  }
  s.clear();
  ind = 0;
  for (int i = 0; i < 2 * n; i++) {
    if (q[i][0] == 1) {
      s.insert(v[ind++]);
    } else {
      if (*s.begin() != q[i][1]) {
        cout << "NO\n";
        return 0;
      }
      s.erase(s.begin());
    }
  }
  cout << "YES\n";
  for (int i = 0; i < n; i++) {
    cout << v[i] + 1 << " ";
  }
  cout << "\n";
  return 0;
}
