require 'prime' A, B = gets.split.map(&:to_i) gcd = A.gcd(B) b = B / gcd if (b.prime_division.map(&:first) - [2, 5]).empty? puts 'No' else puts 'Yes' end