#include <bits/stdc++.h>
using namespace std;
int N, cnt = 1;
int S[200010], chk[200010];
struct DSU {
  int par[200010], L[200010], R[200010];
  void init() {
    for (int i = 0; i <= 2 * N; i++) {
      par[i] = i;
      L[i] = i - 1;
      R[i] = i;
    }
  }
  int f(int u) {
    if (par[u] == u)
      return u;
    else
      return par[u] = f(par[u]);
  }
  void mrg(int u, int v, bool update) {
    u = f(u);
    v = f(v);
    if (u == v) return;
    par[v] = u;
    if (update) {
      chk[R[u]] = cnt;
      chk[L[v]] = cnt;
      cnt++;
    }
    R[u] = R[v];
  }
} dsu;
vector<int> tmp;
int main() {
  scanf("%d", &N);
  scanf("\n");
  for (int i = 1; i < 2 * N; i++) {
    char t;
    scanf("%c", &t);
    S[i] = t - '0';
  }
  S[0] = 1;
  S[2 * N] = 1;
  dsu.init();
  for (int i = 0; i < 2 * N; i++) {
    if (S[i] && S[i + 1]) {
      tmp.push_back(i);
    }
  }
  if (tmp.size() % 2) {
    printf("No");
    return 0;
  }
  if (tmp.size() == 2 && tmp[0] + 1 == tmp[1]) {
    printf("No");
    return 0;
  }
  int n = tmp.size();
  int x = 0;
  int q = n;
  for (int i = 0; i < n - 1; i++) {
    if (tmp[i] + 1 != tmp[i + 1]) {
      if (i >= 3 && n - 5 >= i) {
        q = i + 1;
        break;
      } else if (i < 3 && n - 5 < i) {
        if (tmp[0] + 1 == tmp[1] || tmp[n - 2] + 1 == tmp[n - 1]) continue;
        q = i + 1;
        break;
      } else if (i < 3) {
        if (tmp[0] + 1 == tmp[1]) continue;
        q = i + 1;
        break;
      } else {
        if (tmp[n - 2] + 1 == tmp[n - 1]) continue;
        q = i + 1;
        break;
      }
    }
  }
  for (int i = 0; i < q / 2; i++) {
    dsu.mrg(tmp[i], tmp[i + q / 2] + 1, true);
    dsu.mrg(tmp[i + q / 2], tmp[i] + 1, false);
  }
  for (int i = 0; i < (n - q) / 2; i++) {
    dsu.mrg(tmp[i + q], tmp[i + q + (n - q) / 2] + 1, true);
    dsu.mrg(tmp[i + q + (n - q) / 2], tmp[i + q] + 1, false);
  }
  if (dsu.f(0) == dsu.f(2 * N)) {
    printf("No");
    return 0;
  }
  tmp.clear();
  for (int i = 0; i < 2 * N; i++) {
    if (S[i] && dsu.f(i) != dsu.f(0) && dsu.f(i) != dsu.f(2 * N)) {
      tmp.push_back(dsu.f(i));
    }
  }
  sort(tmp.begin(), tmp.end());
  tmp.resize(unique(tmp.begin(), tmp.end()) - tmp.begin());
  if (tmp.size() == 0) {
    dsu.mrg(0, 2 * N, true);
    int p = 0;
    for (int i = 0; i < 2 * N; i++) {
      if (!chk[i]) {
        chk[i] = cnt;
        cnt += p;
        p ^= 1;
      }
    }
    printf("Yes\n");
    for (int i = 0; i < 2 * N; i++) {
      printf("%d ", chk[i]);
    }
    return 0;
  }
  while (tmp.size() >= 2) {
    int u = tmp.back();
    tmp.pop_back();
    int v = tmp.back();
    tmp.pop_back();
    dsu.mrg(u, v, true);
    tmp.push_back(dsu.f(u));
  }
  dsu.mrg(0, tmp.back(), true);
  dsu.mrg(tmp.back(), 2 * N, true);
  int p = 0;
  for (int i = 0; i < 2 * N; i++) {
    if (!chk[i]) {
      chk[i] = cnt;
      cnt += p;
      p ^= 1;
    }
  }
  printf("Yes\n");
  for (int i = 0; i < 2 * N; i++) {
    printf("%d ", chk[i]);
  }
}
