#include <bits/stdc++.h>
using namespace std;
int f[30];
int gcd(int a, int b) { return b ? gcd(b, a % b) : a; }
int main() {
  int n;
  scanf("%d", &n);
  int odd = -1;
  int imp = 0;
  int g = 0;
  for (int i = 0; i < n; i++) {
    scanf("%d", f + i);
    if (f[i] % 2 == 1) {
      if (odd + 1) imp = 1;
      odd = i;
    }
    g = gcd(f[i], g);
  }
  if (imp) {
    printf("0\n");
    for (int i = 0; i < n; i++)
      for (int j = 0; j < f[i]; j++) printf("%c", i + 'a');
    printf("\n");
    return 0;
  }
  if (g % 2 == 0) {
    printf("%d\n", g);
    for (int i = 0; i < n; i++) f[i] /= g;
    for (int i = 0; i < g; i++) {
      if (i % 2 == 0)
        for (int j = 0; j < n; j++)
          for (int k = 0; k < f[j]; k++) printf("%c", j + 'a');
      else
        for (int j = n - 1; j >= 0; j--)
          for (int k = 0; k < f[j]; k++) printf("%c", j + 'a');
    }
    printf("\n");
  } else {
    printf("%d\n", g);
    f[odd] -= g;
    for (int i = 0; i < n; i++) f[i] /= g;
    for (int i = 0; i < g; i++) {
      printf("%c", odd + 'a');
      for (int j = 0; j < n; j++)
        for (int k = 0; k < f[j] / 2; k++) printf("%c", j + 'a');
      for (int j = n - 1; j >= 0; j--)
        for (int k = 0; k < f[j] / 2; k++) printf("%c", j + 'a');
    }
    printf("\n");
  }
}
