#include <bits/stdc++.h>
using namespace std;
int t1 = 0, t2 = 0;
string s;
void color0(int v = 1) {
  cout << 0;
  t1 += v;
}
void color1(int v = 1) {
  cout << 1;
  t2 += v;
}
int main() {
  int n;
  cin >> n >> s;
  for (int i = 0; i < n; i++) {
    if (s[i] == '(') {
      if (t1 <= t2)
        color0(1);
      else
        color1(1);
    } else {
      if (t1 >= t2)
        color0(-1);
      else
        color1(-1);
    }
  }
  cout << endl;
}
