#include <bits/stdc++.h>
using namespace std;
long long b[26];
long long NOD(long long y1, long long y2) {
  while (y1 != y2) {
    if (y1 > y2)
      y1 -= y2;
    else
      y2 -= y1;
  }
  return y1;
}
int main() {
  ios_base::sync_with_stdio(false);
  long long n, k = 0;
  cin >> n;
  for (long long i = 0; i < n; ++i) {
    cin >> b[i];
    if (b[i] % 2 != 0) ++k;
  }
  if (n == 1) {
    cout << b[0] << "\n";
    for (long long i = 0; i < b[0]; ++i) cout << "a";
    return 0;
  }
  if (k > 1) {
    cout << 0 << "\n";
    for (long long i = 0; i < n; ++i) {
      for (long long j = 0; j < b[i]; ++j) cout << (char)('a' + i);
    }
    return 0;
  }
  long long ONOD = NOD(b[0], b[1]);
  for (long long i = 2; i < n; ++i) ONOD = NOD(ONOD, b[i]);
  if (k == 1) {
    long long ind;
    for (long long i = 0; i < n; ++i)
      if (b[i] % 2 != 0) ind = i;
    b[ind] -= ONOD;
    cout << ONOD << "\n";
    for (long long i = 0; i < n; ++i) b[i] /= ONOD;
    for (long long i = 0; i < ONOD; ++i) {
      for (long long j = 0; j < n; ++j)
        for (long long k = 0; k < b[j] / 2; ++k) cout << (char)('a' + j);
      cout << (char)('a' + ind);
      for (long long j = n - 1; j >= 0; --j)
        for (long long k = 0; k < b[j] / 2; ++k) cout << (char)('a' + j);
    }
  } else {
    cout << ONOD << "\n";
    for (long long i = 0; i < n; ++i) b[i] /= ONOD;
    for (long long i = 0; i < ONOD / 2; ++i) {
      for (long long j = 0; j < n; ++j)
        for (long long k = 0; k < b[j]; ++k) cout << (char)('a' + j);
      for (long long j = n - 1; j >= 0; --j)
        for (long long k = 0; k < b[j]; ++k) cout << (char)('a' + j);
    }
  }
  return 0;
}
