#include <bits/stdc++.h>
using namespace std;
int read() {
  char ch = getchar();
  int x, f = 1;
  while (ch < '0' || ch > '9') {
    if (ch == '-') f = -1;
    ch = getchar();
  }
  x = ch - '0';
  while (1) {
    ch = getchar();
    if (ch < '0' || ch > '9') break;
    x = x * 10 + ch - '0';
  }
  return x * f;
}
const int maxn = 100100;
int n, k, sum[maxn], cnt, ret, all, now = 1, ans[maxn], tot, dan;
int gcd(int a, int b) {
  if (b == 0) return a;
  return gcd(b, a % b);
}
int main() {
  n = read();
  for (int i = 1; i <= n; i++) {
    sum[i] = read();
    if (i == 1)
      ret = sum[i];
    else
      ret = gcd(ret, sum[i]);
    if (sum[i] % 2 == 1) cnt = i, dan++;
    all += sum[i];
  }
  if (n == 1) {
    printf("%d\n", sum[1]);
    for (int i = 1; i <= sum[1]; i++) printf("a");
    return 0;
  }
  if (dan >= 2) {
    printf("0\n");
    for (int i = 1; i <= n; i++)
      for (int j = 1; j <= sum[i]; j++) printf("%c", i + 'a' - 1);
    return 0;
  }
  printf("%d\n", ret);
  if (~ret & 1) ret >>= 1;
  for (int i = 1; i <= n; i++) sum[i] /= ret;
  for (int i = 1; i <= ret; i++) {
    for (int j = 1; j <= n; j++)
      for (int k = 0; k < sum[j] / 2; k++) printf("%c", j + 'a' - 1);
    if (sum[cnt] & 1) printf("%c", cnt + 'a' - 1);
    for (int j = 26; j >= 1; j--)
      for (int k = 0; k < sum[j] / 2; k++) printf("%c", j + 'a' - 1);
  }
  return 0;
}
