#include <bits/stdc++.h>
using namespace std;
const long long maxn = 6e2 + 8;
const long long maxm = 1e7 + 8;
int l[maxn], r[maxn];
stack<int> sk;
void greed(int &n) {
  int pos[2 * maxn];
  char ans[2 * maxn];
  int cnt = -1;
  for (register int i = 1; i <= n; ++i) {
    sk.push(i);
    ans[++cnt] = '(';
    pos[i] = cnt;
    while (!sk.empty()) {
      if (l[sk.top()] + pos[sk.top()] - 1 > cnt) break;
      if (r[sk.top()] + pos[sk.top()] - 1 < cnt) goto label1;
      ans[++cnt] = ')';
      sk.pop();
    }
  }
  if (!sk.empty())
  label1:
    printf("%s\n", "IMPOSSIBLE");
  else
    ans[++cnt] = '\0', printf("%s\n", ans);
}
void dp(int &n) {}
int main() {
  int n;
  scanf("%d", &n);
  for (register int i = 1; i <= n; ++i) scanf("%d%d", &l[i], &r[i]);
  greed(n);
  dp(n);
  return 0;
}
