#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  int a[n], i, j = 0;
  vector<int> v;
  for (i = 0; i < n; i++) cin >> a[i];
  sort(a, a + n);
  v.push_back(a[0]);
  for (i = 1; i < n; i++) {
    if (v[j] == a[i]) continue;
    if (a[i] - v[j] > 1) {
      v.clear();
      v.push_back(a[i]);
      j = 0;
    } else {
      v.push_back(a[i]);
      j++;
    }
    if (v.size() == 3) break;
  }
  if (v.size() == 3)
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
