#include int main(void){ int a,b; scanf("%d%d",&a,&b); if (a%b) { printf("NO\n"); } else { printf("YES\n"); } return 0; }