#include <bits/stdc++.h>
using namespace std;
const int MOD = 998244353;
int n;
string s;
vector<int> hv[2][2];
int ans[200005], cnt;
int main() {
  cin >> n >> s;
  s = "1" + s + "1";
  for (int i = 0; i < (int)(2 * n); i++)
    hv[s[i] - '0'][s[i + 1] - '0'].push_back(i);
  if (hv[1][1].size() % 2 != 0) {
    printf("No\n");
    return 0;
  }
  for (int i = 0; i < (int)(hv[1][0].size()); i++)
    ans[hv[1][0][i]] = ans[hv[0][1][i]] = cnt++;
  for (int i = 0; i < (int)(hv[0][0].size()); i++) {
    ans[hv[0][0][i]] = cnt;
    if (i & 1) cnt++;
  }
  if (hv[1][1].size() % 4 == 0) {
    for (int i = 0; i < (int)(hv[1][1].size()); i++) {
      ans[hv[1][1][i]] = cnt + (i & 1);
      if ((i & 3) == 3) cnt += 2;
    }
    printf("Yes\n");
    for (int i = 0; i < (int)(2 * n); i++) printf("%d ", ans[i] + 1);
    return 0;
  }
  int pos = -1;
  for (int i = 1; i < hv[1][0].size(); i++)
    if (hv[0][1][i - 1] + 1 < hv[1][0][i]) {
      pos = i;
      break;
    }
  if (pos == -1) {
    printf("No\n");
    return 0;
  }
  swap(ans[hv[0][1][pos - 1]], ans[hv[0][1][pos]]);
  int ct = 0;
  for (int i = 0; i < (int)(hv[1][1].size()); i++) {
    if (i + 1 < hv[1][1].size() && hv[1][1][i + 1] == hv[0][1][pos - 1] + 1) {
      ans[hv[1][1][i]] = ans[hv[1][1][i + 1]] = cnt++;
      i++;
      continue;
    }
    ans[hv[1][1][i]] = cnt + (i & 1);
    if ((ct & 3) == 3) cnt += 2;
    ct++;
  }
  printf("Yes\n");
  for (int i = 0; i < (int)(2 * n); i++) printf("%d ", ans[i] + 1);
  return 0;
}
