#include <algorithm>
#include <cassert>
#include <climits>
#include <cmath>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <ctime>
#include <deque>
#include <functional>
#include <iomanip>
#include <iostream>
#include <iterator>
#include <list>
#include <map>
#include <memory>
#include <numeric>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <vector>
//#include <regex>

/* g++ -g -std=c++0x */
/* g++ -g -std=c++11 */

using namespace std;

// std::ios::sync_with_stdio(false);

// freopen("input.txt", "rt", stdin);
// freopen("output.txt", "wt", stdout);

#define ALL(c)          (c).begin(), (c).end()
#define ALLR(c)         (c).rbegin(), (c).rend()
#define FOR(i,a,b)      for (int i=(a); i < (b); ++i)
#define FORR(i,a,b)     for (int i=(a); i > (b); --i)
#define FOR_ALL(i,c)    for (__typeof((c).begin()) i=(c).begin();   \
                             i != (c).end(); ++i)
#define FOR_ALLR(i,c)   for (__typeof((c).rbegin()) i=(c).rbegin(); \
                             i != (c).rend(); ++i)
#define SZ(array)       (sizeof(array)/sizeof(array[0]))
#define lc(x)           (x<<1)     /* 2*x */
#define rc(x)           (x<<1 | 1) /* 2*x+1 */
#define lowbit(x)       (x & (-x)) /* 0b10100 -> 0b100 */

typedef long long       LL;
typedef map<int,int>    MII;
typedef pair<int,int>   PII;
typedef set<int>        SI;
typedef vector<bool>    VB;
typedef vector<double>  VD;
typedef vector<int>     VI;
typedef vector<string>  VS;

/* check if a key is in container C */
template <class C>
inline bool in_(const typename C::key_type& k, const C& A)
{ return A.find(k) != A.end(); }
inline bool in_(const string& s, const string& S)
{ return S.find(s) != string::npos; }

/*
 * Let Xi be the integer in the i-th square (X1 = A, XN = B).
 * Let Yi = X(i+1) - Xi .
 *
 * For each i, -D <= Yi <= -C or C <= Yi <= D must be satisfied.
 * 
 * sum(Yi)|i=[1,N-1] = B - A must be satisfied because
 * sum(Yi) = sum((X(i+1) - Xi) = XN - X1 = B - A.
 * 
 * If you can find Yi that satisfies the conditions above, you can
 * construct a desired sequence by X2 = X1 + Y1, X3 = X2 + Y2, .. Thus,
 * these conditions are sufficient.
 *
 * Suppose that m of Yi satisfy -D <= Yi <= -C and the remaining N-1-m
 * Yi satisfy C <= Yi <= D. By adding these inequalities, we get
 * C(N-1-m) - Dm <= sum(Yi) <= -Cm + (N-1-m)D. Thus,
 * C(N-1-m) - Dm <= B - A   <= -Cm + (N-1-m)D must be satisfied. On the
 * other hand, when this inequality holds, we can find an example of
 * Yi. We can first set the values of Yi to -D or C, and while the sum
 * is smaller than B - A, we can increase integers one by one in the
 * order Y1, Y2, Y3, .. Y(N-1), Y1, Y2, ..
 * => m number of -D followed by (N-1-m) number of C?
 */

int main()
{
/* #ifndef ONLINE_JUDGE */
/*     freopen("foo", "rt", stdin); */
/* #endif */
    LL N,A,B,C,D;
    while (cin >> N >> A >> B >> C >> D) {
        string ans = "NO";
        FOR(m,0,N-1) {
            const LL lft = C*(N-1-m) - D*m;
            const LL rht = -C*m + (N-1-m)*D;
            if (lft <= B-A && B-A <= rht)
                ans = "YES";
        }
        cout << ans << endl;
    }
    return 0;
}


Measured memory_bytes: 256