#include <bits/stdc++.h>
using namespace std;
bool is_prime(long long a) {
  for (long long i = 2; i <= (a / i); i++) {
    if (a % i == 0) {
      return 0;
    }
  }
  return 1;
}
int main() {
  int n;
  cin >> n;
  int arr[n + 1];
  for (int i = 0; i < n; i++) {
    cin >> arr[i];
  }
  sort(arr, arr + n);
  if ((arr[n - 3] + arr[n - 2]) <= arr[n - 1]) {
    cout << "NO\n";
    return 0;
  }
  cout << "YES\n";
  cout << arr[n - 3] << " " << arr[n - 1] << " " << arr[n - 2] << " ";
  for (int i = n - 4; i >= 0; i--) {
    cout << arr[i] << " ";
  }
  cout << "\n";
  ;
}
