#include #include using namespace std; using namespace atcoder; using ll = long long; using ld = long double; int X, Y, N; ld A[101010]; int main() { cin >> X >> Y >> N; for (int i = 1; i <= N; i++) cin >> A[i]; for (int i = 1; i <= N - 1; i++) { ld T = A[i] / X; if (A[i + 1] + 1e-10 < T * Y) { //cout << fixed << setprecision(15) << A[i] << ' ' << A[i + 1] + 1e-10 << ' ' << T * Y << ' ' << T << endl; cout << "NO" << endl; return 0; } } cout << "YES" << endl; return 0; }