#include <bits/stdc++.h>
template <class T>
T abs(T a) {
  if (a < 0) return -a;
  return a;
}
template <class T>
T maxim(T a, T b) {
  if (a > b) return a;
  return b;
}
template <class T>
T minim(T a, T b) {
  if (a < b) return a;
  return b;
}
using namespace std;
int main() {
  int a, b, c, d, n, st1 = 0, st2, go;
  cin >> a >> b >> c >> d >> n;
  vector<int> v(n);
  for (int i = 0; i < n; ++i) cin >> v[i];
  int e = a + c, f = maxim(b, d);
  char res[60][110];
  if ((minim(b, d) % 2 && d > b) || (minim(b, d) % 2 == 0 && d < b))
    st2 = 0, go = 1;
  else
    st2 = a + c - 1, go = 0;
  if (b < d) {
    for (int i = b; i < f; ++i)
      for (int j = 0; j < a; ++j) *(*(res + i) + j) = '.';
  } else {
    for (int i = d; i < f; ++i)
      for (int j = a; j < e; ++j) *(*(res + i) + j) = '.';
  }
  int i = 0, begin = 0, end = a + c - 1;
  while (v[n - 1]) {
    res[st1][st2] = i + 'a';
    v[i]--;
    if (!v[i]) i++;
    if ((go && st2 == end) || (!go && st2 == begin)) {
      st1++;
      if (go)
        st2++;
      else
        st2--;
      if (st1 == minim(b, d)) {
        if (b < d)
          begin = a;
        else
          end = a - 1;
      }
      go = !go;
    }
    if (go) {
      st2++;
    } else
      st2--;
  }
  cout << "YES" << endl;
  for (int i = 0; i < f; i++) {
    for (int j = 0; j < e; ++j) cout << *(*(res + i) + j);
    cout << endl;
  }
}
