#include <bits/stdc++.h>
int a, b, c, d, n, x[32];
char g[128][128];
void fill(int t, int l, int x, int y, char z) {
  for (int i = 0; i < x; ++i)
    for (int j = 0; j < y; ++j) g[t + i][l + j] = z;
}
int main() {
  scanf("%d%d%d%d%d", &a, &b, &c, &d, &n);
  int h = b < d ? d : b;
  fill(1, 1, h, a + c, '.'), fill(1, 1, b, a, '?'), fill(1, a + 1, d, c, '?');
  for (int i = 0, d = a & 1, u = d ? b : 1, v = 1, x;
       i < n && 1 == scanf("%d", &x); ++i) {
    while (x-- > 0) {
      g[u][v] = 'a' + i;
      int p = d ? u - 1 : u + 1, q = v;
      if ('?' != g[p][q]) p = u, ++q, d = !d;
      u = p, v = q;
    }
  }
  puts("YES");
  for (int i = 1; i <= h; ++i) puts(g[i] + 1);
}
