#include <bits/stdc++.h>
using namespace std;
long long int n, m, i, j, k, o, four;
bool t1, t2, t3;
char c1, c2;
int main() {
  cin >> n >> m;
  long long int a[m + 1];
  for (int i = int(0); i <= int(m - 1); i++) {
    cin >> a[i];
  }
  sort(a, a + m);
  if (a[m - 1] == n || a[0] == 1) {
    cout << "NO" << endl;
    return 0;
  }
  for (int i = int(1); i <= int(m - 1); i++) {
    if (a[i] - a[i - 1] == 1) {
      k++;
    } else {
      k = 0;
    }
    if (k == 2) {
      cout << "NO" << endl;
      return 0;
    }
  }
  cout << "YES" << endl;
  return 0;
}
