#include <bits/stdc++.h>
using namespace std;
const double eps = 1e-8;
char ch[100][100];
int tot[30], a, b, c, d;
int dir, n, L, x, y;
int ok[100][100];
int main() {
  cin >> a >> b >> c >> d >> n;
  for (int i = 1; i <= n; i++) cin >> tot[i];
  memset(ok, 0, sizeof(ok));
  for (int i = 1; i <= b; i++)
    for (int j = 1; j <= a; j++) ok[i][j] = 1;
  for (int i = 1; i <= d; i++)
    for (int j = a + 1; j <= a + c; j++) ok[i][j] = 1;
  L = (min(b, d) & 1) ? 1 : 0;
  if ((L && b < d) || (!L && b > d))
    dir = 1, y = 0;
  else
    dir = -1, y = a + c + 1;
  x = 1;
  for (int i = 1; i <= n; i++)
    for (; tot[i]; tot[i]--) {
      y += dir;
      if (!ok[x][y]) x++, y -= dir, dir *= -1;
      ch[x][y] = char(96 + i);
    }
  cout << "YES" << endl;
  for (int i = 1; i <= max(b, d); i++) {
    for (int j = 1; j <= a + c; j++)
      if (!ok[i][j])
        cout << ".";
      else
        cout << ch[i][j];
    cout << endl;
  }
  return 0;
}
