#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m, d, c[1005], plat = 0;
  cin >> n >> m >> d;
  for (int i = 0; i < m; i++) {
    cin >> c[i];
    plat += c[i];
  }
  vector<int> v(m + 1);
  int h = 1;
  bool flag = 0;
  while (h < d) {
    for (int i = 0; i <= m; i++) {
      if (plat == n) {
        flag = 1;
        break;
      }
      v[i]++;
      plat++;
    }
    if (flag) break;
    h++;
  }
  if (plat == n) {
    cout << "YES" << endl;
    for (int i = 0; i < m; i++) {
      for (int j = 0; j < v[i]; j++) cout << "0 ";
      for (int j = 0; j < c[i]; j++) cout << i + 1 << " ";
    }
    for (int j = 0; j < v[m]; j++) cout << "0 ";
    cout << endl;
  } else
    cout << "NO" << endl;
  return 0;
}
