#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #define int long long #define rep(i, n) for (int i = 0; i < (n); i++) #define P pair #define sz(x) x.size() #define ALL(x) (x).begin(),(x).end() #define ALLR(x) (x).rbegin(),(x).rend() #define VE vector #define COUT(x) cout<<(x)< #define SE set #define PQ priority_queue template inline bool chmin(T& a, T b) { if (a > b) { a = b; return true; } return false; } template inline bool chmax(T& a, T b) { if (a < b) { a = b; return true; } return false; } using namespace std; typedef long long ll; using Graph = vector>; ll gcd(ll a, ll b) { if (a < b)swap(a, b); if (b == 0) return a; return gcd(b, a % b); } ll lcm(ll a, ll b) { ll g = gcd(a, b); return a / g * b; } bool prime(int n) { for (int i = 2; i <= sqrt(n); i++) { if (n%i == 0)return false; } return n != 1; } const long long MOD = 1000000007; const long long INF = 1LL << 50; // pair -> vector> // AandB.push_back(make_pair(a[i],b[i])) signed main() { ios_base::sync_with_stdio(0); cin.tie(0); int a, b; cin >> a >> b; if (lcm(a, b) == max(a, b)) { cout << "YES" << endl; } else { cout << "NO" << endl; } return 0; }