#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);
std::vector<int> go(int n, string 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) {
    return std::vector<int>();
  }
  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) {
    return std::vector<int>();
  }
  if (gr11.size() == 1 && cnt11 % 4 == 2) {
    return std::vector<int>();
  }
  if (cnt11 % 4 == 2) {
    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.empty() && gr11[0].empty()) gr11.pop_front();
  }
  std::vector<int> ag;
  for (auto x : gr11)
    for (auto y : x) ag.push_back(y);
  for (int i = 0; i < ag.size(); i += 4) {
    ans[ag[i]] = cnt;
    ans[ag[i + 2]] = cnt++;
    ans[ag[i + 1]] = cnt;
    ans[ag[i + 3]] = cnt++;
  }
  if (rev) {
    reverse((ans).begin(), (ans).end());
  }
  return ans;
}
string from(int n, std::vector<int> ans) {
  string fr(2 * n - 1, '0');
  int cur = 0;
  map<int, std::vector<int>> to;
  for (int i = 0; i < 2 * n; i++) to[ans[i]].push_back(i);
  std::vector<int> pr(2 * n, 0);
  for (auto x : to) {
    pr[x.second[0]] = x.second[1];
    pr[x.second[1]] = x.second[0];
  }
  while (1) {
    cur = pr[cur];
    if (cur == 2 * n - 1) break;
    fr[cur++] = '1';
  }
  return fr;
}
int main() {
  int n;
  scanf("%d\n", &n);
  string s;
  getline(cin, s);
  std::vector<int> ans = go(n, s);
  if (ans.empty()) {
    printf("No");
  } else {
    printf("Yes\n");
    for (auto x : ans) printf("%d ", x);
  }
}
