#include <bits/stdc++.h>
using namespace std;
const int MAX = 111111, MAX2 = 575;
int n;
int a[100000];
int nsd(int a, int b) {
  if (!a || !b) return a + b;
  return nsd(b % a, a);
}
int main() {
  cin >> n;
  int b = 0, q = 0;
  string s = "";
  int type = 0;
  for (int(i) = (0); i < (n); ++(i)) {
    cin >> a[i];
    if (a[i] % 2 == 1) b++, type = i;
    q = nsd(q, a[i]);
  }
  if (n == 1) {
    cout << a[0] << endl;
    for (int(i) = (0); i < (a[0]); ++(i)) cout << 'a';
    return 0;
  }
  if (b >= 2) {
    cout << "0\n";
    for (int(i) = (0); i < (n); ++(i))
      for (int(j) = (0); j < (a[i]); ++(j)) cout << char(i + 'a');
    return 0;
  }
  if (b == 1) {
    cout << q << "\n";
    s = "";
    for (int(i) = (0); i < (n); ++(i))
      for (int(j) = (0); j < (a[i] / (2 * q)); ++(j)) {
        s += char(i + 'a');
      }
    string s0 = s;
    reverse(s0.begin(), s0.end());
    s += char(type + 'a') + s0;
    for (int(i) = (0); i < (q); ++(i)) cout << s;
    return 0;
  }
  cout << q << "\n";
  s = "";
  for (int(i) = (0); i < (n); ++(i))
    for (int(j) = (0); j < (a[i] / q); ++(j)) {
      s += char(i + 'a');
    }
  string s0 = s;
  reverse(s0.begin(), s0.end());
  s += s0;
  q /= 2;
  for (int(i) = (0); i < (q); ++(i)) cout << s;
  return 0;
}
