#include <bits/stdc++.h>
using namespace std;
int32_t main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  long long n;
  cin >> n;
  string s;
  cin >> s;
  stack<long long> r;
  stack<long long> b;
  string ans = "";
  long long rr = 0, bb = 0;
  for (long long i = 0; i < n; i++) {
    if (s[i] == '(') {
      if (rr <= bb) {
        r.push(1);
        ans += "1";
        rr++;
      } else {
        b.push(0);
        ans += "0";
        bb++;
      }
    } else {
      if (rr >= bb) {
        r.pop();
        ans += "1";
        rr--;
      } else {
        b.pop();
        ans += "0";
        bb--;
      }
    }
  }
  cout << ans;
}
