#include <bits/stdc++.h>
using namespace std;
string p = "-1";
vector<string> v;
struct st {
  int a, id;
} s[1111];
bool cp(st l, st r) { return l.a < r.a; }
string getS() {
  string r = p;
  if (r == "-1")
    r = "0";
  else {
    int id = r.size() - 1;
    while (id >= 0) {
      if (r[id] == '0') break;
      r[id] = '0';
      id--;
    }
    if (id >= 0)
      r[id] = '1';
    else
      r = "-1";
  }
  return r;
}
int main() {
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> s[i].a;
    s[i].id = i;
  }
  sort(s, s + n, cp);
  v.resize(n);
  for (int i = 0; i < n; i++) {
    string str = getS();
    if (str == "-1" || str.size() > s[i].a) {
      p = "NO";
      break;
    }
    while (str.size() != s[i].a) str.push_back('0');
    v[s[i].id] = str;
    p = str;
  }
  if (p == "NO")
    cout << p << endl;
  else {
    cout << "YES" << endl;
    for (int i = 0; i < v.size(); i++) cout << v[i] << endl;
  }
  return 0;
}
