#include <bits/stdc++.h>   using namespace std;   const int N = 1e5 + 10, M = 30;   int a[M], b[M];   char ans[26 * N];   int gcd(int x, int y) { return (!y) ? x : gcd(y, x % y); }   int main() {     ios::sync_with_stdio(0);     int n, cnt = 0, sum = 0, pos = 0, qaq = 0, tmp = 0;     scanf( %d , &n);     for (int i = 1; i <= n; i++) {       scanf( %d , &a[i]);       cnt += a[i] % 2;       sum += a[i];     }     if (cnt > 1) {       cout << 0 << endl;       for (int i = 1; i <= n; i++)         for (int j = 1; j <= a[i]; j++) cout << char( a  + i - 1);       return 0;     }     for (int i = 1; i <= n; i++) qaq = gcd(a[i], qaq);     if (!cnt) qaq /= 2;     for (int i = 1; i <= n; i++) {       a[i] /= qaq;       if (a[i] % 2) tmp = i;     }     sum /= qaq;     for (int i = 1; i <= n; i++) {       if (tmp == i) continue;       for (int j = 1; j <= a[i] / 2; j++) ans[++pos] =  a  + i - 1;     }     for (int i = 1; i <= n; i++) {       if (tmp != i) continue;       for (int j = 1; j <= a[i]; j++) ans[++pos] =  a  + i - 1;     }     for (int i = sum; i >= sum / 2 + 1; i--) ans[i] = ans[sum - i + 1];     if (!cnt)       printf( %d n , qaq * 2);     else       printf( %d n , qaq);     for (int i = 1; i <= qaq; i++) printf( %s , ans + 1);     return 0;   }   