func_code_string: #include <bits/stdc++.h>   using namespace std;   const int MAXN = 1000000 + 10;   const int MAXM = 600000 + 10;   int a[64][64];   int ans, n, m;   inline int sg(int x) { return 1 - 2 * x; }   inline int sg(int s, int x) { return sg(s >> x & 1); }   int main() {     ios::sync_with_stdio(false);     cin >> n;     m = n >> 1;     for (int i = 0; i < n; i++)       for (int j = 0; j < n; j++) cin >> a[i][j];     int ans = 0;     for (int s = 0; s < (1 << m + 1); s++) {       int ret = a[m][m] * sg(s, m);       for (int j = 0; j < m; j++)         ret +=             a[m][j] * sg(s, j) + a[m][j + m + 1] * sg(s >> j & 1 ^ (s >> m & 1));       for (int i = 0; i < m; i++) {         int tmp1 = a[i][m] + a[i + m + 1][m] * sg(s, m);         int tmp2 = -tmp1;         for (int j = 0; j < m; j++)           tmp1 += abs(a[i][j] + a[i + m + 1][j] * sg(s, j) + a[i][j + m + 1] +                       a[i + m + 1][j + m + 1] * sg(s >> j & 1 ^ (s >> m & 1)));         for (int j = 0; j < m; j++)           tmp2 +=               abs(a[i][j] + a[i + m + 1][j] * sg(s, j) - a[i][j + m + 1] +                   a[i + m + 1][j + m + 1] * sg(s >> j & 1 ^ (s >> m & 1) ^ 1));         ret += max(tmp1, tmp2);       }       ans = max(ans, ret);     }     cout << ans << endl;     return 0;   }   