func_code_string: #include <bits/stdc++.h>   using namespace std;   const int mN = 30;   int a[mN];   int n;   void output(int x) {     string s;     string mid;     for (int i = 1; i <= n; i++) {       if (a[i] / x % 2) mid += char(i +  a  - 1);       for (int j = 1; j <= a[i] / x / 2; j++) s += char(i +  a  - 1);     }     s += mid;     for (int i = n; i >= 1; i--) {       for (int j = 1; j <= a[i] / x / 2; j++) s += char(i +  a  - 1);     }     for (int i = 1; i <= x; i++) {       cout << s;       reverse(s.begin(), s.end());     }   }   int gcd(int x, int y) {     if (x % y == 0) return y;     return gcd(y, x % y);   }   int main() {     cin >> n;     int odd = 0;     for (int i = 1; i <= n; i++) {       cin >> a[i];       if (a[i] % 2) odd++;     }     int maxl = a[1];     for (int i = 2; i <= n; i++) maxl = gcd(maxl, a[i]);     if (odd > 1) {       cout << 0 << endl;       output(1);     } else if (maxl > 1) {       if (odd <= 1) {         cout << maxl << endl;         output(maxl);       }     } else {       cout << maxl << endl;       output(maxl);     }   }   