#include <bits/stdc++.h>
using namespace std;
const int N = 100000 + 5;
int n, a[N];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  sort(a + 1, a + n + 1);
  if (a[n - 2] + a[n - 1] > a[n]) {
    puts("YES");
    for (int i = 1; i <= n; i++)
      if (i % 2 == 1) printf("%d ", a[i]);
    for (int i = n; i >= 1; i--)
      if (i % 2 == 0) printf("%d ", a[i]);
  } else
    puts("NO");
  return 0;
}
