#include <iostream>
using namespace std;

int main() {
  int x, y;
  cin >> x >> y;
  cout << ((y % x == 0)?"Yes":"No");
  return 0;
}
#include<bits/stdc++.h>
#include<cstdio>

using namespace std;

typedef long long int ll;
typedef unsigned long long int ull;
typedef pair<int,int> pair;

#define MOD 1000000007
#define rep(i, n) for(int i = 0; i < (int)(n); i++)


int main(void){
  int m,h;
  cin >> m >> h;

  if(h%m==0) puts("Yes");
  else puts("No");
}