func_code_string: #include <bits/stdc++.h>   using namespace std;   int n, m;   long long k;   int res[1000];   long long dp[205][205];   int p[105][105];   pair<int, int> a[10005];   long long calc(int i, int j) {     if (j < 0) return 0;     if (i == n + m - 1) {       return (j == 0);     }     if (dp[i][j] != -1) return dp[i][j];     long long &ans = dp[i][j];     ans = 0;     if (res[i] != 0)       ans = calc(i + 1, j + res[i]);     else {       ans = calc(i + 1, j + 1) + calc(i + 1, j - 1);     }     if (ans >= k) ans = k;     return ans;   }   long long solve() {     memset(dp, -1, sizeof(dp));     return calc(0, 0);   }   int main() {     cin >> n >> m >> k;     for (int i = 0; i < n; ++i) {       for (int j = 0; j < m; ++j) {         int x;         cin >> x;         a[x - 1] = make_pair(i, j);       }     }     for (int l = 0; l < n * m; ++l) {       int i = a[l].first;       int j = a[l].second;       if (res[i + j] == 0) {         res[i + j] = 1;         long long cur = solve();         if (cur >= k) continue;         k -= cur;         res[i + j] = -1;       }     }     for (int i = 0; i < n; ++i) {       for (int j = 0; j < m; ++j) {         if (res[i + j] == 1)           putchar( ( );         else           putchar( ) );       }       puts(  );     }     return 0;   }   