#include <bits/stdc++.h>
using namespace std;
using ll = long long int;
using ii = pair<ll, ll>;
using vi = vector<int>;
using vii = vector<ii>;
using graph = vector<vi>;
const int INF = 0x3f3f3f3f;
const ll INFL = 0x3f3f3f3f3f3f3f3f;
const int MAXN = 512345;
const ll mod = 998244353;
int main() {
  ios::sync_with_stdio(0);
  int n, m, k;
  string s;
  cin >> n >> s;
  vector<char> r, b;
  string ans = "";
  for (int i = 0; i < n; ++i) {
    auto c = s[i];
    if (c == '(') {
      if (r.size() <= b.size()) {
        ans += '0';
        r.push_back(c);
      } else {
        ans += '1';
        b.push_back(c);
      }
    } else {
      if (r.size() > b.size()) {
        ans += '0';
        r.pop_back();
      } else {
        ans += '1';
        b.pop_back();
      }
    }
  }
  cout << ans << '\n';
}
