#include<bits/stdc++.h>
using namespace std;
typedef long long ll;
typedef pair<int,int> P;
int main(){
  int n,p;
  cin>>n;
  int x[n],a[n*n],u[n];
  vector<P> v;
  for(int i=0;i<n*n;i++) a[i]=0;
  for(int i=0;i<n;i++){
    cin>>x[i];
    u[i]=1;
    a[x[i]-1]=i+1;
    v.push_back(P(x[i]-1,i+1));
  }
  sort(v.begin(),v.end());
  bool f=1;
  p=0;
  for(int i=0;i<n;i++){
    int c=v[i].second;
    while(u[c-1]<c){
      if(p>=n*n){
	f=0;
	break;
      }
      if(a[p]){
	p++;
	continue;
      }
      if(p>v[i].first){
	f=0;
	break;
      }
      a[p]=c;
      u[c-1]++;
    }
  }
  p=n-1;
  for(int i=0;i<n*n;i++){
    if(a[i]) continue;
    while(u[p]==n) p--;
    if(i<a[p]){
      f=0;
      break;
    }
    a[i]=p+1;
    u[p]++;
  }
  if(!f){
    cout<<"No"<<endl;
  }else{
    cout<<"Yes"<<endl;
    for(int i=0;i<n*n;i++) cout<<a[i]<<" \n"[i==n*n-1];
  }
  return 0;
}
