#include <bits/stdc++.h>
using namespace std;
void start() {}
void sober() {
  long long int n, x = 0, a = 0, b = 0, y = 0, sum = 0, k = 0, m = 0;
  cin >> n;
  vector<long long int> v(n);
  vector<long long int> odd, even;
  for (long long int i = 0; i < n; i++) {
    cin >> v[i];
    if (v[i] & 1) {
      a++;
    } else {
      b++;
    }
  }
  sort(begin(v), end(v));
  if (v[n - 1] >= v[n - 2] + v[n - 3]) {
    cout << "NO\n";
    return;
  }
  cout << "YES\n";
  for (long long int i = n - 1; i >= 0; i -= 2) {
    cout << v[i] << ' ';
  }
  for (long long int i = n % 2; i < n; i += 2) {
    cout << v[i] << ' ';
  }
  return;
}
signed main() {
  start();
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  long long int t = 1;
  while (t--) {
    sober();
  }
}
