#include <bits/stdc++.h>
using namespace std;
const long long int N = 1e5 + 5, inf = 1e18;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long int n;
  cin >> n;
  set<long long int> S;
  long long int un = 0;
  long long int f = 0;
  long long int pos[n + 1];
  vector<long long int> v;
  long long int ans[2 * n];
  memset(ans, 0, sizeof(ans));
  for (long long int i = 0; i < 2 * n; ++i) {
    char c;
    cin >> c;
    if (c == '+') {
      S.insert(i);
      v.push_back(0);
    } else {
      long long int a;
      cin >> a;
      v.push_back(a);
      pos[a] = i;
    }
  }
  for (long long int i = 1; i < n + 1; ++i) {
    auto it = S.lower_bound(pos[i]);
    if (it == S.begin()) {
      f = 1;
      break;
    } else {
      it--;
      ans[*it] = i;
      S.erase(it);
    }
  }
  if (f == 1) {
    cout << "NO"
         << "\n";
    return 0;
  }
  set<long long int> S2;
  for (long long int i = 0; i < ((long long int)((v).size())); ++i) {
    if (v[i] == 0) {
      S2.insert(ans[i]);
    } else {
      if (((long long int)((S2).size())) == 0) {
        f = 1;
        break;
      }
      auto it = S2.begin();
      if (*(it) != v[i]) {
        f = 1;
        break;
      } else {
        S2.erase(it);
      }
    }
  }
  if (f == 1) {
    cout << "NO"
         << "\n";
    return 0;
  } else {
    cout << "YES"
         << "\n";
    for (long long int i = 0; i < ((long long int)((v).size())); ++i) {
      if (v[i] == 0) {
        cout << ans[i] << " ";
      }
    }
  }
  cout << "\n";
  return 0;
}
