#include <bits/stdc++.h>
using namespace std;
typedef struct {
  int a, b, c, d, n;
} data;
typedef struct {
  int i, j, I, J;
} sea;
bool starting_direction(int b, int d) {
  if (b > d) {
    if (d % 2 == 0)
      return true;
    else
      return false;
  } else {
    if (b % 2 == 0)
      return false;
    else
      return true;
  }
}
sea fill_sea(vector<vector<char>>& map, data in) {
  sea ret;
  if (in.b > in.d) {
    ret.i = in.d;
    ret.I = in.b - 1;
    ret.j = in.a;
    ret.J = map[in.d].size() - 1;
  } else {
    ret.i = in.b;
    ret.I = in.d - 1;
    ret.j = 0;
    ret.J = in.a - 1;
  }
  for (int i = ret.i; i <= ret.I; i++)
    for (int j = ret.j; j <= ret.J; j++) map[i][j] = '.';
  return ret;
}
void enche(vector<vector<char>>& map, data in, vector<int>& territory) {
  sea nope = fill_sea(map, in);
  bool start = starting_direction(in.b, in.d);
  char letter = 'a';
  int index = 0;
  for (int i = 0; i < map.size(); i++) {
    for (int j = 0; j < map[i].size(); j++) {
      int real_j;
      if (start == (i % 2 == 0)) {
        real_j = j;
      } else {
        real_j = map[i].size() - j - 1;
      }
      if (nope.i <= i && i <= nope.I && nope.j <= real_j && real_j <= nope.J)
        continue;
      map[i][real_j] = (char)(letter + index);
      territory[index]--;
      if (territory[index] == 0) {
        index++;
      }
    }
  }
}
int main() {
  data in;
  cin >> in.a >> in.b >> in.c >> in.d >> in.n;
  vector<vector<char>> map;
  map.resize(max(in.b, in.d));
  for (int i = 0; i < map.size(); i++) map[i].resize(in.a + in.c);
  vector<int> territory;
  territory.resize(in.n);
  for (int i = 0; i < territory.size(); i++) cin >> territory[i];
  enche(map, in, territory);
  cout << "YES" << '\n';
  for (int i = 0; i < map.size(); i++) {
    for (int j = 0; j < map[i].size(); j++) {
      cout << map[i][j];
    }
    cout << '\n';
  }
}
