#include <bits/stdc++.h>
using namespace std;
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  ;
  long long k;
  cin >> k;
  string s;
  cin >> s;
  stack<long long> st;
  long long index = 0;
  map<long long, long long> mp;
  for (long long i = 0; i < s.length(); i++) {
    if (s[i] == '(') {
      if (st.empty()) {
        st.push(0);
      } else {
        if (st.top() == 0)
          st.push(1);
        else
          st.push(0);
      }
      mp[i] = st.top();
    } else {
      long long u = st.top();
      st.pop();
      mp[i] = u;
    }
  }
  for (long long i = 0; i < s.length(); i++) cout << mp[i];
}
