#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int t, n, m, i;
  cin >> n >> m;
  long long int a[m];
  for (i = 0; i < m; i++) cin >> a[i];
  sort(a, a + m);
  bool ok = true;
  if (a[m - 1] == n || a[0] == 1) {
    cout << "NO";
    return 0;
  }
  for (i = 0; i < m - 2; i++) {
    if (a[i + 1] - a[i] == 1) {
      if (a[i + 2] - a[i + 1] == 1) {
        ok = false;
        break;
      }
    }
  }
  if (ok)
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
