#include <bits/stdc++.h>
using namespace std;
const int MAXN = 100010;
long long s[MAXN];
long long d[MAXN], c[MAXN];
int n;
long long t1, t2;
int z;
long long M = 1;
void exgcd(long long a, long long b, long long &d, long long &x, long long &y) {
  if (a == 0) {
    y = 1;
    x = 0;
    d = b;
    return;
  }
  exgcd(b % a, a, d, y, x);
  x -= (b / a) * y;
  return;
}
void Er() {
  printf("NO\n");
  exit(0);
}
long long gcd(long long a, long long b) {
  long long d, x, y;
  exgcd(a, b, d, x, y);
  return d;
}
bool check(long long a, long long b, long long d, long long x) {
  if (d == 0) return true;
  if (b == 0) return false;
  if (a / d != x / b) return a / d > x / b;
  a %= d;
  x %= b;
  return !check(d, x, a, b);
}
long long lcm(long long a, long long b) {
  long long d = gcd(a, b);
  if (check(a, b, d, t1)) Er();
  return a / d * b;
}
long long mul(long long a, long long b) {
  if (b == 0) return 0;
  long long x = mul(a, b / 2);
  x += x;
  if (b & 1) x += a;
  return x % M;
}
long long solve(long long p, long long q) {
  long long d, x, y;
  long long t = M / q;
  exgcd(t, q, d, x, y);
  if (p % d != 0) Er();
  if (x < 0) x += M;
  return mul(mul(t, (p / d)), x);
}
bool work(long long y, long long x) {
  for (int i = 1; i <= n; i++) {
    if (x > t2) return false;
    if (gcd(y, x) != s[i]) return false;
    x++;
  }
  return true;
}
void add(long long k) {
  long long n1 = 0;
  long long m1 = 1, m2;
  long long p1 = 0, p2;
  bool ok = true;
  for (int i = 1; i <= n; i++) {
    p2 = s[i] - (i - 1);
    long long cnt = 0;
    m2 = k;
    ok = true;
    while (s[i] % m2 == 0) {
      cnt++;
      if (!check(m2, k, 1, M))
        m2 *= k;
      else {
        ok = false;
        break;
      }
    }
    if (ok) m2 /= k;
    p2 %= m2;
    p2 += m2;
    p2 %= m2;
    if (cnt > n1) {
      swap(cnt, n1);
      swap(m1, m2);
      swap(p1, p2);
    }
    if (p1 % m2 != p2 % m2) Er();
  }
  z++;
  d[z] = m1;
  c[z] = p1;
  return;
}
int main() {
  scanf("%I64d%I64d%d", &t1, &t2, &n);
  for (int i = 1; i <= n; i++) scanf("%I64d", &s[i]);
  for (int i = 1; i <= n; i++) M = lcm(M, s[i]);
  long long t = M;
  for (long long i = 2; i * i <= t; i++)
    if (t % i == 0) {
      while (t % i == 0) t /= i;
      add(i);
    }
  if (t > 1) add(t);
  long long x = 0;
  for (int i = 1; i <= z; i++) {
    c[i] = c[i] % d[i] + d[i];
    c[i] %= d[i];
    x += solve(c[i], d[i]);
    x %= M;
    x += M;
    x %= M;
  }
  if (x == 0) x = M;
  if (work(M, x))
    printf("YES\n");
  else
    printf("NO\n");
  return 0;
}
