#include <bits/stdc++.h>
using namespace std;
int main() {
  int a, b, c, d;
  int n;
  cin >> a >> b >> c >> d >> n;
  vector<int> data(n);
  for (int i = 0; i < n; i++) {
    scanf("%d", &data[i]);
  }
  n = max(b, d);
  int m = a + c;
  vector<vector<int> > ans(n, vector<int>(m, -1));
  int p = 0, cnt = 0;
  if (b & 1) {
    for (int i = b - 1; i >= 0; i--) {
      if (!(i & 1)) {
        for (int j = 0; j < a; j++) {
          if (cnt >= data[p]) {
            cnt = 0;
            p++;
          }
          ans[i][j] = p;
          cnt++;
        }
      } else {
        for (int j = a - 1; j >= 0; j--) {
          if (cnt >= data[p]) {
            cnt = 0;
            p++;
          }
          ans[i][j] = p;
          cnt++;
        }
      }
    }
  } else {
    for (int i = b - 1; i >= 0; i--) {
      if (!(i & 1)) {
        for (int j = 0; j < a; j++) {
          if (cnt >= data[p]) {
            cnt = 0;
            p++;
          }
          ans[i][j] = p;
          cnt++;
        }
      } else {
        for (int j = a - 1; j >= 0; j--) {
          if (cnt >= data[p]) {
            cnt = 0;
            p++;
          }
          ans[i][j] = p;
          cnt++;
        }
      }
    }
  }
  for (int i = 0; i < d; i++) {
    for (int j = a; j < m; j++) {
      if (cnt >= data[p]) {
        cnt = 0;
        p++;
      }
      ans[i][j] = p;
      cnt++;
    }
  }
  printf("YES\n");
  for (int i = 0; i < n; i++) {
    for (int j = 0; j < m; j++) {
      if (ans[i][j] == -1) {
        printf(".");
        continue;
      }
      printf("%c", (char)('a' + ans[i][j]));
    }
    printf("\n");
  }
  return 0;
}
