#include <bits/stdc++.h>
using namespace std;
int L[1220], R[1220], s[1220], pos[1220];
char ans[1220];
int main() {
  int n, ok = 1, all = 0, top = 0;
  scanf("%d", &n);
  for (int i = 1; i <= n; ++i) {
    scanf("%d%d", &L[i], &R[i]);
    if (!ok) continue;
    pos[i] = all;
    ans[all++] = '(';
    s[++top] = i;
    while (top > 0 && pos[s[top]] + L[s[top]] <= all) {
      if (pos[s[top]] + R[s[top]] >= all)
        ans[all++] = ')';
      else {
        ok = 0;
        break;
      }
      top--;
    }
  }
  if (top > 0) ok = 0;
  if (ok)
    printf("%s\n", ans);
  else
    puts("IMPOSSIBLE");
  return 0;
}
