def solve() a,b=gets.split.map(&:to_i) for i in 1..a do if a % i == 0 && i % b == 0 then return "YES" end end "NO" end puts solve()