#include <bits/stdc++.h>
using namespace std;
struct _ {
  _() { ios_base::sync_with_stdio(0); }
} _;
template <class A, class B>
ostream &operator<<(ostream &o, pair<A, B> t) {
  o << "(" << t.first << ", " << t.second << ")";
  return o;
}
template <class T>
string tostring(T first, int len = 0, char c = '0') {
  stringstream ss;
  ss << first;
  string r = ss.str();
  if (r.length() < len) r = string(len - r.length(), c) + r;
  return r;
}
template <class T>
void PV(T a, T b, int n = 0, int w = 0, string s = " ") {
  int c = 0;
  while (a != b) {
    cout << tostring(*a++, w, ' ');
    if (a != b && (n == 0 || ++c % n))
      cout << s;
    else
      cout << endl;
  }
}
template <class T>
inline bool chmin(T &a, T b) {
  return a > b ? a = b, 1 : 0;
}
template <class T>
inline bool chmax(T &a, T b) {
  return a < b ? a = b, 1 : 0;
}
const long long linf = 0x3f3f3f3f3f3f3f3fLL;
const int inf = 0x3f3f3f3f;
const int mod = int(1e9) + 7;
const int N = 105;
int n, m;
long long k;
int d[N][N];
long long dp[3 * N][3 * N];
int a[3 * N];
int ord[3 * N];
long long f() {
  memset(dp, 0, sizeof(dp));
  ;
  dp[1][0] = 1;
  for (int i = 2; i <= n + m; i++) {
    for (int j = 0; j <= i; j++) {
      if (a[i] == 0) {
        if (j > 0) {
          if (dp[i - 1][j - 1] >= linf)
            dp[i][j] = linf;
          else
            dp[i][j] += dp[i - 1][j - 1];
        }
        if (dp[i - 1][j + 1] >= linf)
          dp[i][j] = linf;
        else
          dp[i][j] += dp[i - 1][j + 1];
      } else if (a[i] == 1) {
        if (j > 0) {
          if (dp[i - 1][j - 1] >= linf)
            dp[i][j] = linf;
          else
            dp[i][j] += dp[i - 1][j - 1];
        }
      } else {
        if (dp[i - 1][j + 1] >= linf)
          dp[i][j] = linf;
        else
          dp[i][j] += dp[i - 1][j + 1];
      }
    }
  }
  return dp[n + m][0];
}
int main() {
  cin >> n >> m >> k;
  memset(ord, 0x3f, sizeof(ord));
  ;
  for (int i = 1; i <= n; i++)
    for (int j = 1; j <= m; j++) {
      cin >> d[i][j];
      chmin(ord[i + j], d[i][j]);
    }
  vector<pair<int, int> > vp;
  for (int i = 2; i <= n + m; i++) vp.push_back(make_pair(ord[i], i));
  sort((vp).begin(), (vp).end());
  memset(a, 0, sizeof(a));
  ;
  long long cnt = 0;
  for (int i = 0; i < n + m - 1; i++) {
    a[vp[i].second] = 1;
    long long r = f();
    if (cnt + r < k) {
      cnt += r;
      a[vp[i].second] = -1;
    }
  }
  vector<string> res(n, string(m, 0));
  for (int i = 1; i <= n; i++)
    for (int j = 1; j <= m; j++) res[i - 1][j - 1] = a[i + j] == 1 ? '(' : ')';
  PV((res).begin(), (res).end(), 1);
  return 0;
}
