#include <bits/stdc++.h>
using namespace std;
const long long mod = 1000000007;
const unsigned gen_seed =
    std::chrono::system_clock::now().time_since_epoch().count();
std::mt19937_64 gen(gen_seed);
int main() {
  int n;
  scanf("%d\n", &n);
  string s;
  getline(cin, s);
  int rev = 0;
  if (s[0] == '0' && s.back() == '1') {
    reverse((s).begin(), (s).end());
    rev = 1;
  }
  s = "1" + s + "1";
  deque<deque<int>> gr11(1);
  int cnt11 = 0;
  std::vector<int> a10, a01;
  std::vector<int> a00;
  for (int i = 0; i < 2 * n; i++) {
    if (s[i] == '1' && s[i + 1] == '1') {
      gr11.back().push_back(i);
      cnt11++;
    } else if (!gr11.back().empty())
      gr11.push_back(deque<int>());
    if (s[i] == '1' && s[i + 1] == '0') a10.push_back(i);
    if (s[i] == '0' && s[i + 1] == '1') a01.push_back(i);
    if (s[i] == '0' && s[i + 1] == '0') a00.push_back(i);
  }
  if (gr11.back().empty()) gr11.pop_back();
  if (cnt11 % 2 != 0) {
    cout << "No";
    return 0;
  }
  std::vector<int> pr(2 * n, -1);
  int cnt = 1;
  std::vector<int> ans(2 * n, -1);
  for (int i = 0; i < a00.size(); i += 2) {
    ans[a00[i]] = cnt;
    ans[a00[i + 1]] = cnt++;
  }
  for (int i = 0; i < a10.size(); i++) {
    ans[a10[i]] = cnt;
    ans[a01[i]] = cnt++;
  }
  if (gr11.size() <= 2 && gr11.size() >= 1 && gr11[0][0] == 0 &&
      gr11.back().back() == 2 * n - 1 && cnt11 % 4 == 2) {
    cout << "No";
    return 0;
  }
  while (1) {
    if (gr11.size() > 3 ||
        (gr11.size() == 3 && (gr11[0].size() > 1 || gr11[1].size() > 1 ||
                              gr11[2].size() % 4 == 0))) {
      int u = gr11[0][0];
      int v = gr11[1][0];
      int ru = gr11[0].back() + 1;
      int rv = gr11[1].back() + 1;
      ans[u] = cnt;
      ans[v] = cnt++;
      swap(ans[ru], ans[rv]);
      gr11[0].pop_front();
      gr11[1].pop_front();
      if (gr11[1].empty()) swap(gr11[0], gr11[1]);
      while (gr11[0].empty()) gr11.pop_front();
    } else if (gr11.size() == 3) {
      int u = gr11[0][0];
      int v = gr11[2][0];
      int ru = gr11[0].back() + 1;
      int rv = gr11[2].back() + 1;
      ans[u] = cnt;
      ans[v] = cnt++;
      swap(ans[ru], ans[rv]);
      gr11[0].pop_front();
      gr11[2].pop_front();
      gr11.pop_front();
    } else if (gr11.size() == 2 && gr11[0].size() > 1 && gr11[1].size() > 1) {
      int u = gr11[0][0];
      int v = gr11[1][0];
      int ru = gr11[0].back() + 1;
      int rv = gr11[1].back() + 1;
      ans[u] = cnt;
      ans[v] = cnt++;
      swap(ans[ru], ans[rv]);
      gr11[0].pop_front();
      gr11[1].pop_front();
    } else if (gr11.size() == 2) {
      for (int j = 0; j < 2; j++) {
        while (gr11[j].size() > 4) {
          ans[gr11[j][0]] = cnt;
          ans[gr11[j][2]] = cnt++;
          ans[gr11[j][1]] = cnt;
          ans[gr11[j][3]] = cnt++;
          for (int it = 0; it < 4; it++) gr11[j].pop_front();
        }
      }
      if (gr11[0].size() == 1 && gr11[1].size() == 1) {
        int u = gr11[0][0];
        int v = gr11[1][0];
        int ru = gr11[0].back() + 1;
        int rv = gr11[1].back() + 1;
        ans[u] = cnt;
        ans[v] = cnt++;
        swap(ans[ru], ans[rv]);
      } else if (gr11[0].size() == 1) {
        ans[gr11[0][0]] = cnt;
        ans[gr11[1][1]] = cnt++;
        ans[gr11[1][0]] = cnt;
        ans[gr11[1][2]] = cnt++;
      } else {
        ans[gr11[1][0]] = cnt;
        ans[gr11[0][1]] = cnt++;
        ans[gr11[0][0]] = cnt;
        ans[gr11[0][2]] = cnt++;
      }
      break;
    } else if (gr11.size() == 1) {
      for (int i = 0; i < gr11[0].size(); i += 4) {
        ans[gr11[0][i]] = cnt;
        ans[gr11[0][i + 2]] = cnt++;
        ans[gr11[0][i + 1]] = cnt;
        ans[gr11[0][i + 3]] = cnt++;
      }
      break;
    } else if (gr11.empty())
      break;
  }
  if (rev) {
    reverse((ans).begin(), (ans).end());
  }
  printf("Yes\n");
  for (auto x : ans) printf("%d ", x);
}
