#include <bits/stdc++.h>
using namespace std;
const double eps = 1e-9;
int fx[] = {-1, 1, 0, 0, -1, -1, 1, 1};
int fy[] = {0, 0, -1, 1, -1, 1, -1, 1};
int kx[] = {1, 1, 2, 2, -1, -1, -2, -2};
int ky[] = {2, -2, 1, -1, 2, -2, 1, -1};
int TLx[] = {0, -1, -1, 0};
int TLy[] = {-1, -1, 0, 0};
int TRx[] = {-1, -1, 0, 0};
int TRy[] = {0, 1, 1, 0};
int BLx[] = {0, 1, 1, 0};
int BLy[] = {-1, -1, 0, 0};
int BRx[] = {0, 1, 1, 0};
int BRy[] = {1, 1, 0, 0};
int A[100005];
priority_queue<int> pq;
int main() {
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> A[i];
    pq.push(A[i]);
  }
  deque<int> ans;
  for (int i = 1; i <= n; i++) {
    if (i & 1)
      ans.push_front(pq.top());
    else
      ans.push_back(pq.top());
    pq.pop();
  }
  A[0] = ans.back();
  A[n + 1] = ans.front();
  for (int i = 1; i <= n; i++) {
    A[i] = ans.front();
    ans.pop_front();
  }
  for (int i = 1; i <= n; i++) {
    if (A[i] >= A[i - 1] + A[i + 1]) {
      cout << "NO" << endl;
      return 0;
    }
  }
  cout << "YES" << endl;
  for (int i = 1; i <= n; i++) {
    cout << A[i] << ' ';
  }
  cout << endl;
  return 0;
}
