#include <bits/stdc++.h>
volatile bool isLocalTestEnabled = 0;
bool g_isLocalPrintEnabled = (bool)(0);
template <typename T>
void UpdateMin(T& a, const T b) {
  a = std::min(a, b);
}
template <typename T>
void UpdateMax(T& a, const T b) {
  a = std::max(a, b);
}
const long double Pi = std::atan(1.0L) * 4.0L;
static const long double Eps = 1.0e-09;
template <typename T>
bool IsEqual(const T a, const T b) {
  return std::abs(a - b) < Eps;
}
template <typename T>
bool IsGreater(const T a, const T b) {
  return a > b + Eps;
}
template <typename T>
bool IsLess(const T a, const T b) {
  return a + Eps < b;
}
template <typename T>
bool IsGreaterEqual(const T a, const T b) {
  return !IsLess(a, b);
}
template <typename T>
bool IsLessEqual(const T a, const T b) {
  return !IsGreater(a, b);
}
template <typename T>
std::string ToStr(const T& val) {
  std::ostringstream ostr;
  ostr << val;
  return ostr.str();
}
template <typename T>
bool FromStr(const std::string& str, T& val) {
  std::istringstream istr(str);
  istr >> val;
  return !!istr;
}
template <typename T>
std::istream& operator>>(std::istream& ist, std::vector<T>& data) {
  ;
  for (size_t i = 0; i < data.size(); i++) {
    ist >> data[i];
  }
  return ist;
}
template <typename T>
T Read(std::istream& ist) {
  ;
  T val;
  ist >> val;
  return val;
}
template <typename T>
std::ostream& operator<<(std::ostream& ost, const std::vector<T>& data) {
  for (size_t i = 0; i < data.size(); i++) {
    if (i != 0) {
      ost << ' ';
    }
    ost << data[i];
  }
  return ost;
}
template <size_t id>
class StopWatch {};
template <typename T>
static T FindGcd(T a, T b) {
  if (a < b) std::swap(a, b);
  if (b == 0) return a;
  do {
    if (a < b) std::swap(a, b);
    a = a % b;
  } while (a != 0);
  return b;
}
size_t FindGcd(const std::vector<size_t>& a) {
  size_t gc = a[0];
  for (size_t i = 1; i < a.size(); i++) {
    gc = FindGcd(gc, a[i]);
  }
  return gc;
}
std::vector<size_t> ToChain(const std::vector<size_t>& a) {
  std::vector<size_t> b;
  for (size_t i = 0; i < a.size(); i++) {
    b.insert(b.end(), a[i], i);
  }
  return b;
}
std::string ToChars(const std::vector<size_t>& b) {
  std::string s;
  for (size_t i = 0; i < b.size(); i++) {
    s += (char)('a' + b[i]);
  }
  return s;
}
bool Solve(std::istream& ist, std::ostream& ost, const bool multipleTestMode) {
  StopWatch<1> sw;
  (void)sw;
  size_t n;
  ist >> n;
  if (multipleTestMode && !ist) return false;
  std::vector<size_t> a(n);
  ist >> a;
  if (!g_isLocalPrintEnabled) {
  } else
    std::cout << std::endl << "Next test: " << a << std::endl;
  const size_t gc = FindGcd(a);
  size_t oddsCount = 0;
  size_t lastOddIndex = 0;
  for (size_t i = 0; i < a.size(); i++) {
    if (a[i] % 2 == 0) continue;
    oddsCount += 1;
    lastOddIndex = i;
  }
  if (n == 1) {
    const std::string ans = ToChars(ToChain(a));
    ost << a[0] << std::endl;
    ost << ans << std::endl;
  } else if (oddsCount > 1) {
    const std::string ans = ToChars(ToChain(a));
    ost << 0 << std::endl;
    ost << ans << std::endl;
  } else if (oddsCount == 1) {
    const char centerChar = (char)('a' + lastOddIndex);
    const size_t centerSize = gc;
    const std::string center(centerSize, centerChar);
    std::vector<size_t> aEvens = a;
    aEvens[lastOddIndex] -= gc;
    std::for_each(aEvens.begin(), aEvens.end(), [&gc](size_t& z) {
      ;
      z /= gc * 2;
    });
    std::string base;
    {
      std::string internalBase = ToChars(ToChain(aEvens));
      base += internalBase;
      base += centerChar;
      std::reverse(internalBase.begin(), internalBase.end());
      base += internalBase;
    }
    std::string ans;
    for (size_t i = 0; i < gc; i++) {
      ans += base;
      std::reverse(base.begin(), base.end());
    }
    ost << gc << std::endl;
    ost << ans << std::endl;
    return multipleTestMode;
  } else {
    ;
    std::vector<size_t> aEvens = a;
    std::for_each(aEvens.begin(), aEvens.end(), [&gc](size_t& z) {
      ;
      z /= gc;
    });
    std::string base = ToChars(ToChain(aEvens));
    std::string ans;
    for (size_t i = 0; i < gc; i++) {
      ans += base;
      std::reverse(base.begin(), base.end());
    }
    ost << gc << std::endl;
    ost << ans << std::endl;
  }
  return multipleTestMode;
}
int main(int argc, const char* argv[]) {
  std::ios_base::sync_with_stdio(false);
  std::istream* ist = &std::cin;
  std::ostream* ost = &std::cout;
  std::unique_ptr<std::istream> fileInput;
  if (argc > 1) {
    fileInput.reset(new std::ifstream(argv[1]));
    if (!(*fileInput)) {
      std::cout << "File not found: " << argv[1] << std::endl;
    }
    ist = fileInput.get();
  }
  Solve(*ist, *ost, false);
}
