#include <bits/stdc++.h>
using namespace std;
const int N = 200005;
vector<int> li[N], id;
char s[N];
int n, m, L, ec, sum, mark[N];
void markit() {
  if (id.size() & 3) {
    fprintf(stderr, "SEGMENTION FAULT!");
    exit(1);
  }
  for (int i = 0; i << 2 < id.size(); i++) {
    for (int j : {0, 1})
      for (int k : {0, 1}) mark[id[i << 2 | j << 1 | k]] = ec + k + 1;
    ec += 2;
  }
}
void output() {
  puts("Yes");
  for (int i = 0; i < L; i++) {
    if (!mark[i]) mark[i] = ec < 0 ? -ec : ++ec, ec = -ec;
    printf("%d ", mark[i]);
  }
  exit(0);
}
int main() {
  scanf("%d", &n);
  scanf("%s", s + 1);
  s[0] = '1';
  L = n << 1;
  for (int i = 0, j; i < L; i++)
    if (s[i] == '0' && s[(i + 1) % L] == '1') {
      for (li[m].push_back(i), j = (i + 1) % L; s[j] == '1'; j = (j + 1) % L)
        li[m].push_back(j);
      m++;
    }
  if (!m) {
    li[1 << 30].push_back(1);
    if (~n & 1) {
      puts("Yes");
      for (int i = 0; i < L; i++) id.push_back(i);
      markit();
      output();
    } else
      puts("No"), exit(0);
  }
  for (int i = 0; i < m; i++) sum += ((int)li[i].size()) - 2;
  if (sum & 1) puts("No"), exit(0);
  if (sum & 2) {
    for (int i = 0; i < m; i++)
      if (((int)li[i].size()) > 2) li[m - 1].swap(li[i]);
    for (int i = 0; i < m - 1; i++)
      if (((int)li[i].size()) > 2) {
        vector<int> &a = li[i], &b = li[m - 1];
        int la = ((int)a.size()) - 1, lb = ((int)b.size()) - 1, ea = a[la],
            eb = b[lb];
        mark[a[la - 1]] = mark[b[lb - 1]] = ++ec;
        a.pop_back();
        b.pop_back();
        a.pop_back();
        b.pop_back();
        a.push_back(eb);
        b.push_back(ea);
        sum -= 2;
        break;
      }
    if (sum & 2) puts("No"), exit(0);
  }
  for (int i = 0; i < m; i++) {
    mark[li[i][0]] = ec + 1 + i;
    mark[li[i][((int)li[i].size()) - 1]] = ec + 1 + (i + 1) % m;
    for (int j = 1; j < ((int)li[i].size()) - 1; j++) id.push_back(li[i][j]);
  }
  ec += m;
  markit();
  output();
  return 0;
}
