#include <bits/stdc++.h>
using namespace std;
vector<vector<long long> > gr;
int a, b, c, d, n;
bool good(int I, int I2) {
  if (I < 0 || I2 < 0 || I >= max(b, d) || I2 >= a + c) return 0;
  if (I < min(b, d)) return 1;
  if (b > d) {
    if (I2 >= a) return 0;
    return 1;
  } else {
    if (I2 < a) return 0;
    return 1;
  }
}
int main() {
  cin.tie(0);
  cin.sync_with_stdio(0);
  cin >> a >> b >> c >> d >> n;
  gr.assign(max(b, d), vector<long long>(a + c, '.'));
  vector<long long> v(n);
  for (long long i = 0; i < (n); i++) cin >> v[i];
  int sl = min(b, d);
  bool l;
  int stI = 0;
  int stI2 = 0;
  if (sl % 2 == 0) {
    if (b > d) {
      l = 0;
      stI = 0;
      stI2 = 0;
    } else {
      l = 1;
      stI = 0;
      stI2 = a + c - 1;
    }
  } else {
    if (b > d) {
      l = 1;
      stI = 0;
      stI2 = a + c - 1;
    } else {
      l = 0;
      stI = 0;
      stI2 = 0;
    }
  }
  int I = stI;
  int I2 = stI2;
  int o = 0;
  while (1) {
    if (!v[o]) {
      o++;
    }
    if (o == n) break;
    v[o]--;
    gr[I][I2] = o + 'a';
    if (l) {
      if (!good(I, I2 - 1)) {
        l = 0;
        I++;
      } else {
        I2--;
      }
    } else {
      if (!good(I, I2 + 1)) {
        l = 1;
        I++;
      } else {
        I2++;
      }
    }
  }
  cout << "YES\n";
  for (long long i = 0; i < (max(b, d)); i++) {
    int I = i;
    for (long long i = 0; i < (a + c); i++) {
      cout << (char)gr[I][i];
    }
    cout << '\n';
  }
  return 0;
}
