#include <bits/stdc++.h>
using namespace std;
int in() {
  int x;
  return cin >> x, x;
}
template <class T, class L>
bool smax(T& x, L y) {
  return x < y ? (x = y, 1) : 0;
}
template <class T, class L>
bool smin(T& x, L y) {
  return x > y ? (x = y, 1) : 0;
}
const int maxn = 26 + 17;
int n, a[maxn], ans;
int gcd(int a, int b) { return b ? gcd(b, a % b) : a; }
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) scanf("%d", &a[i]), ans = gcd(a[i], ans);
  if (n == 1) {
    printf("%d\n", a[0]);
    while (a[0]--) putchar('a');
    putchar('\n');
    return 0;
  }
  int boy = 0;
  for (int i = 0; i < n; i++) boy += a[i] & 1;
  if (boy > 1) {
    printf("0\n");
    for (int i = 0; i < n; i++)
      while (a[i]--) putchar(i + 'a');
    putchar('\n');
    return 0;
  }
  if (ans % 2 == 1) {
    printf("%d\n", ans);
    int nini;
    for (int i = 0; i < n; i++)
      if (a[i] & 1) nini = i;
    string go;
    for (int i = 0; i < n; i++)
      for (int j = 0; j < a[i] / ans / 2; j++) go.push_back(i + 'a');
    string rgo = go;
    reverse(rgo.begin(), rgo.end());
    go += 'a' + nini;
    go += rgo;
    for (int i = 0; i < ans; i++) cout << go;
    putchar('\n');
    return 0;
  }
  printf("%d\n", ans);
  string go, rgo;
  for (int i = 0; i < n; i++)
    for (int j = 0; j < a[i] / ans; j++) go.push_back(i + 'a');
  rgo = go;
  reverse(rgo.begin(), rgo.end());
  for (int i = 0; i < ans; i++)
    if (i & 1)
      cout << rgo;
    else
      cout << go;
  putchar('\n');
  return 0;
}
