#include <bits/stdc++.h>
using namespace std;
int a[550];
int c[550], b[550];
int main() {
  int n, ans = 0;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
    ans += a[i];
  }
  int sum = 2 * (n - 1);
  if (ans < sum) {
    printf("NO\n");
  } else {
    printf("YES ");
    int cnt = 0, tot = 0;
    for (int i = 1; i <= n; i++) {
      if (a[i] == 1)
        b[cnt++] = i;
      else
        c[tot++] = i;
    }
    if (cnt >= 2)
      printf("%d\n%d\n", tot + 1, n - 1);
    else
      printf("%d\n%d\n", tot - 1 + cnt, n - 1);
    int i, j = 1;
    while (j < tot) {
      printf("%d %d\n", c[j], c[j - 1]);
      a[c[j]]--;
      a[c[j - 1]]--;
      j++;
    }
    if (cnt >= 1) printf("%d %d\n", b[0], c[0]);
    a[c[0]]--;
    i = cnt - 1;
    for (int j = tot - 1; j >= 0; j--) {
      while (i >= 1 && a[c[j]]) {
        printf("%d %d\n", b[i], c[j]);
        a[c[j]]--;
        i--;
      }
    }
  }
  return 0;
}
