#include <bits/stdc++.h>
using namespace std;
const int maxn = 2e5 + 10;
const double inf = 1e9;
const long long mod = 1e9 + 7;
long long _pow(long long a, long long b) {
  long long ans = 1;
  while (b) {
    if (b & 1) ans = ans * a % mod;
    a = a * a % mod;
    b >>= 1;
  }
  return ans;
}
long long a[maxn];
int main() {
  ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> a[i];
  }
  sort(a + 1, a + n + 1);
  if (a[n - 1] + a[n - 2] <= a[n]) {
    cout << "NO" << endl;
    return 0;
  }
  cout << "YES" << endl;
  for (int i = 1; i <= n; i += 2) {
    cout << a[i] << " ";
  }
  if (n % 2 == 1) n--;
  for (int i = n; i >= 2; i -= 2) {
    cout << a[i] << " ";
  }
  cout << endl;
  return 0;
}
