#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
using namespace std;
const long double eps = 1e-7;
const int inf = 1000000010;
const long long INF = 10000000000000010LL;
const int mod = 1000000007;
const int MAXN = 100010, LOG = 20;
int A[MAXN];
bool check(vector<int> &B, int x) {
  int n = B.size();
  sort(B.begin(), B.end());
  for (int i = 0; 2 * i < n; i++) A[i] = B[2 * i];
  for (int i = 1, j = n - 1; i < n; i += 2, j--) A[j] = B[i];
  A[n] = A[0];
  for (int i = 0; i < n; i++)
    if (abs(A[i] - A[i + 1]) > x) return 0;
  return 1;
}
int n, m, k, u, v, x, y, t, a, b, ans;
int B[MAXN];
vector<int> v1, v2;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cin >> n;
  for (int i = 0; i < n; i++) cin >> A[i];
  for (int i = 0; i < n; i++) {
    if (A[i] & 1)
      v1.push_back(A[i]);
    else
      v2.push_back(A[i]);
  }
  cerr << "v1.size()" << '=' << (v1.size()) << endl;
  cerr << "v2.size()" << '=' << (v2.size()) << endl;
  if (v1.size() != v2.size() || !check(v1, 2) || !check(v2, 2))
    return cout << "NO" << '\n', 0;
  for (int i : v2) v1.push_back(i);
  if (!check(v1, 1)) return cout << "NO" << '\n', 0;
  return cout << "YES" << '\n', 0;
  return 0;
}
