#include <bits/stdc++.h>   using namespace std;   const int INF = 1e9 + 1000;   const long long INF64 = 1e18;   const int N = 1001000;   const int MOD = 1e9 + 7;   const double EPS = 1E-9;   long long gcd(long long a, long long b) { return a == 0 ? b : gcd(b % a, a); }   int add(int first, int second, int m) {     first += second;     while (first >= m) first -= m;     while (first < 0) first += m;     return first;   }   int sub(int first, int second, int m) { return add(first, -second, m); }   int mul(int first, int second, int m) { return (first * 1ll * second) % m; }   int binpow(int first, int second, int m) {     int z = 1;     while (second) {       if (second & 1) z = mul(z, first, m);       first = mul(first, first, m);       second >>= 1;     }     return z;   }   int divide(int first, int second, int m) {     return mul(first, binpow(second, m - 2, m), m);   }   int main() {     ios_base::sync_with_stdio(false);     cin.tie(0);     cout.tie(0);     int first, t, a, b, da, db;     cin >> first >> t >> a >> b >> da >> db;     if (first == 0) {       cout <<  YES n ;       return 0;     }     for (int ta = 0; ta < t; ++ta) {       for (int tb = 0; tb < t; ++tb) {         if (a - da * ta + b - db * tb == first || a - da * ta == first ||             b - db * tb == first) {           cout <<  YES n ;           return 0;         }       }     }     cout <<  NO n ;   }   