#include <bits/stdc++.h>
using namespace std;
namespace ib {
char b[100];
}
inline void pi(int x) {
  if (x == 0) {
    putchar(48);
    return;
  }
  if (x < 0) {
    putchar('-');
    x = -x;
  }
  char *s = ib::b;
  while (x) *(++s) = x % 10, x /= 10;
  while (s != ib::b) putchar(*(s--) + 48);
}
inline void ri(int &x) {
  x = 0;
  static char c;
  bool t = 0;
  while (c = getchar(), c < '0' || c > '9')
    if (c == '-')
      t = 1;
    else
      t = 0;
  do x = x * 10 + c - '0';
  while (c = getchar(), c >= '0' && c <= '9');
  if (t) x = -x;
}
namespace io {
const int SIZE = (1 << 21) + 1;
char ibuf[SIZE], *iS, *iT;
template <class I>
inline void gi(I &x) {
  x = 0;
  static char c;
  bool t = 0;
  while (c = getchar(), c < '0' || c > '9')
    if (c == '-')
      t = 1;
    else
      t = 0;
  do x = x * 10 + c - '0';
  while (c = getchar(), c >= '0' && c <= '9');
  if (t) x = -x;
}
}  // namespace io
using io::gi;
char s[400024];
bool st[400024];
int ans[400024];
int main() {
  int i, n, gs = 0;
  ri(n);
  scanf("%s", s + 1);
  for (i = 1; i < n + n; ++i)
    if (s[i] == '1') st[i] = 1;
  st[0] = st[n + n] = 1;
  for (i = 1; i <= n + n; ++i)
    if (st[i - 1] == 1 && st[i] == 1) ++gs;
  if (gs % 4 == 1 || gs % 4 == 3) {
    puts("No");
    return 0;
  }
  if (gs % 4 == 0) {
    int gs = 0, now = 1;
    for (i = 1; i <= n + n; ++i)
      if (st[i - 1] == 1 && st[i] == 1) {
        ++gs;
        if (gs == 1)
          ans[i] = now;
        else if (gs == 2)
          ans[i] = now + 1;
        else if (gs == 3)
          ans[i] = now;
        else
          ans[i] = now + 1, now += 2, gs = 0;
      }
    for (i = 1; i <= n + n; ++i)
      if (st[i - 1] != st[i]) {
        ++gs;
        ans[i] = now;
        if (gs == 2) gs = 0, ++now;
      }
    for (i = 1; i <= n + n; ++i)
      if (st[i - 1] == 0 && st[i] == 0) {
        ++gs;
        ans[i] = now;
        if (gs == 2) gs = 0, ++now;
      }
    puts("Yes");
    for (i = 1; i <= n + n; ++i) pi(ans[i]), putchar(' ');
  } else {
    int gs = 0, now = 1;
    for (i = 1; i < n + n; ++i)
      if (st[i - 1] == 1 && st[i] == 1 && st[i + 1] != 1) ++gs;
    if (gs < 2) {
      puts("No");
      return 0;
    }
    gs = 0;
    for (i = 1; i <= n + n; ++i)
      if (st[i - 1] != st[i]) {
        ++gs;
        if (gs == 1)
          ans[i] = now, ans[i == 1 ? n + n : i - 1] = now + 2;
        else if (gs == 2)
          ans[i] = now + 1, ans[i == n + n ? 1 : i + 1] = now + 2;
        else if (gs == 3)
          ans[i] = now + 1;
        else {
          ans[i] = now;
          break;
        }
      }
    now += 3;
    gs = 0;
    for (++i; i <= n + n; ++i)
      if (st[i - 1] != st[i]) {
        ++gs;
        ans[i] = now;
        if (gs == 2) gs = 0, ++now;
      }
    gs = 0;
    for (i = 1; i <= n + n; ++i)
      if (st[i - 1] == 1 && st[i] == 1 && ans[i] == 0) {
        ++gs;
        if (gs == 1)
          ans[i] = now;
        else if (gs == 2)
          ans[i] = now + 1;
        else if (gs == 3)
          ans[i] = now;
        else
          ans[i] = now + 1, now += 2, gs = 0;
      }
    gs = 0;
    for (i = 1; i <= n + n; ++i)
      if (st[i - 1] == 0 && st[i] == 0) {
        ++gs;
        ans[i] = now;
        if (gs == 2) gs = 0, ++now;
      }
    puts("Yes");
    for (i = 1; i <= n + n; ++i) pi(ans[i]), putchar(' ');
  }
  return 0;
}
