#include <bits/stdc++.h>
using namespace std;
const int MAXN = 30;
int n;
int niz[MAXN];
int gcd(int a, int b) {
  if (!a) return b;
  return gcd(b % a, a);
}
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) scanf("%d", &niz[i]);
  if (n == 1) {
    printf("%d\n", niz[0]);
    for (int i = 0; i < niz[0]; i++) printf("a");
    return 0;
  }
  int num = 0;
  for (int i = 0; i < n; i++)
    if (niz[i] % 2 == 1) num++;
  if (num > 1) {
    printf("0\n");
    for (int i = 0; i < n; i++)
      for (int j = 0; j < niz[i]; j++) cout << ((char)('a' + i));
  } else if (num == 1) {
    int g = niz[0];
    for (int i = 0; i < n; i++) g = gcd(g, niz[i]);
    printf("%d\n", g);
    char taj;
    string s;
    for (int i = 0; i < n; i++) {
      niz[i] /= g;
      if (niz[i] % 2 == 1) {
        taj = (char)('a' + i);
        niz[i]--;
      }
      for (int j = 0; j < niz[i] / 2; j++) s.push_back((char)('a' + i));
    }
    string rj = s;
    rj.push_back(taj);
    reverse(s.begin(), s.end());
    rj += s;
    for (int i = 0; i < g; i++) cout << rj;
  } else if (num == 0) {
    int g = niz[0];
    for (int i = 0; i < n; i++) g = gcd(g, niz[i]);
    printf("%d\n", g);
    string s;
    for (int i = 0; i < n; i++) {
      niz[i] /= g;
      for (int j = 0; j < niz[i]; j++) s.push_back((char)('a' + i));
    }
    string rj = s;
    reverse(s.begin(), s.end());
    rj += s;
    for (int i = 0; i < g / 2; i++) cout << rj;
  }
}
