#include <bits/stdc++.h>
using namespace std;
long long mod = 1000000007;
signed main() {
  std::ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long int n;
  cin >> n;
  long long int a[n];
  for (long long int i = 0; i < n; i++) cin >> a[i];
  sort(a, a + n);
  long long int b[n];
  long long int x = 1;
  vector<long long int> r, l;
  for (long long int i = n - 2; i >= 0; i -= 2) {
    r.push_back(a[i]);
  }
  for (long long int i = n - 3; i >= 0; i -= 2) {
    l.push_back(a[i]);
  }
  reverse(l.begin(), l.end());
  long long int sl = l.size(), sr = r.size();
  for (long long int i = 0; i < sl; i++) b[i] = l[i];
  b[sl] = a[n - 1];
  for (long long int i = 0; i < sr; i++) b[i + sl + 1] = r[i];
  long long int flag = 1;
  for (long long int i = 0; i < n; i++) {
    if (i == 0) {
      if (b[i] >= b[i + 1] + b[n - 1]) {
        flag == 0;
        break;
      }
    } else if (i == n - 1) {
      if (b[i] >= b[n - 2] + b[0]) {
        flag = 0;
        break;
      }
    } else {
      if (b[i] >= b[i - 1] + b[i + 1]) {
        flag = 0;
        break;
      }
    }
  }
  if (flag == 1) {
    cout << "YES" << '\n';
    for (long long int i = 0; i < n; i++) cout << b[i] << " ";
    cout << '\n';
  } else
    cout << "NO" << '\n';
  return 0;
}
long long int gcd(long long int a, long long int b) {
  if (a == 0) return b;
  return gcd(b % a, a);
}
long long int fast_power(long long int base, long long int power,
                         long long int MOD) {
  long long int result = 1;
  while (power > 0) {
    if (power & 1) result = (result * base) % MOD;
    base = (base * base) % MOD;
    power >>= 1;
  }
  return result;
}
