#include <bits/stdc++.h>
using namespace std;
int main() {
  vector<string> mp;
  string alpha;
  int a, b, c, d, n;
  cin >> a >> b >> c >> d >> n;
  for (int i = 0; i < n; i++) {
    int x;
    cin >> x;
    alpha += string(x, 'a' + i);
  }
  reverse(alpha.begin(), alpha.end());
  mp.resize(max(b, d));
  for (int i = 0; i < max(b, d); i++) {
    mp[i] = string(a + c, '.');
    for (int j = 0; j < a; j++)
      if (i < b) mp[i][j] = '*';
    for (int j = a; j < a + c; j++)
      if (i < d) mp[i][j] = '*';
  }
  int dir = 1;
  if (min(b, d) % 2 == 1) dir *= -1;
  if (b < d) dir *= -1;
  int alpha_i = 0;
  for (int i = 0; i < max(b, d); i++) {
    if (dir == 1) {
      for (int j = 0; j < a + c; j++)
        if (mp[i][j] == '*') mp[i][j] = alpha.back(), alpha.pop_back();
    } else {
      for (int j = a + c - 1; j >= 0; j--)
        if (mp[i][j] == '*') mp[i][j] = alpha.back(), alpha.pop_back();
    }
    dir *= -1;
  }
  cout << "YES" << endl;
  for (int i = 0; i < max(b, d); i++) cout << mp[i] << endl;
  return 0;
}
