#include <bits/stdc++.h>
using namespace std;
template <class T>
inline void mini(T &a, T b) {
  if (b < a) a = b;
}
template <class T>
inline void maxi(T &a, T b) {
  if (b > a) a = b;
}
int main() {
  ios_base::sync_with_stdio(false);
  int n, m;
  int A[3000];
  cin >> n >> m;
  for (int i = 0; i < m; i++) cin >> A[i];
  sort(A, A + m);
  bool f = true;
  if (A[0] == 1 || A[m - 1] == n) {
    cout << "NO" << endl;
    return 0;
  }
  for (int i = 0; i < m - 2; i++) {
    if (A[i] + 1 == A[i + 1] && A[i + 1] + 1 == A[i + 2]) {
      f = false;
      break;
    }
    if (A[i] == 1 || A[i] == n) {
      f = false;
      break;
    }
  }
  if (f)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
}
