a,b = map(int,input().split()) for c in range(b,a+1) : if a % c == 0 and c % b == 0 : print("YES") break else : print("NO")