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