
main :: IO ()
main = do
    [n,a,b,c,d] <- getInts
    putStrLn $ if solve n a b c d then "YES" else "NO"

getInts :: IO [Int]
getInts = map read . words <$> getLine

solve :: Int -> Int -> Int -> Int -> Int -> Bool
solve n a b c d
    | abs b > a + d*(n-1) = False
    | otherwise = or $ map (\i -> a+i*c+(i-n+1)*d <= b && b <= a+(i-n+1)*c+i*d) [0..n-1]
