#include <iostream>

using namespace std;

int main()
{
  long long N, A, B, C, D;
  cin >> N >> A >> B >> C >> D;
  for (long long m = 0; m <= N - 1; m++) {
    long long n = N - 1 - m;
    if (m*C - n*D <= B - A && B - A <= m*D - n*C) {
      cout << "YES" << endl;
      return 0;
    }
  }
  cout << "NO" << endl;
  return 0;
}