judge::Int->Int->Bool
judge a n | n == 1 = True
          | a == 1 = False
          | n `mod` a == 0 = n `div` a < 10
          | otherwise = judge (a-1) n

main = do
  n <- readLn
  putStrLn $ if judge 9 n then "Yes" else "No"