#include #include using namespace std; using namespace atcoder; using ll=long long; using ld=long double; ld pie=3.141592653589793; ll mod=1000000007; ll inf=999999999999999999; int main(){ ll x,y; cin >> x >> y; queue>que; que.push({x,y}); while (!que.empty()) { ll a=que.front().first; ll b=que.front().second; que.pop(); if (a==0||b==0) { cout << "Yes" << endl; return 0; } if (a%2&&b%2) { continue; } if (a%2) { a-=1; b/=2; que.push({a,b}); }else if (b%2) { b-=1; a/=2; que.push({a,b}); }else{ if ((a/2)%2) { a-=1; b/=2; que.push({a,b}); }else if ((b/2)%2) { b-=1; a/=2; que.push({a,b}); }else{ a-=1; b/=2; que.push({a,b}); } } } cout << "No" << endl; }