#include #define FOR(i,a,b) for(int i=(a);i<(b);++i) #define REP(i,n) for(int i=0;i<(n);++i) #define FORq(i, m, n) for(int i = (m);i <= (n);++i) #define SCD(n) scanf("%d",&n) #define SCD2(m,n) scanf("%d%d",&m,&n) #define SCD3(m,n,k) scanf("%d%d%d",&m,&n,&k) #define PB push_back #define MP make_pair #define ARSCD(A,N) REP(i,N){SCD(A[i]);} #define ARSCD1(A,N) FORq(i,1,N){SCD(A[i]);} #define PRINTD(n) printf("%d\n",n) #define PRINTLLD(n) printf("%lld\n",n) #define DEBUG printf("%s\n","debug") #define fst first #define snd second #define IN(x,S) (S.count(x) != 0) using namespace std; typedef pair PII; typedef vector VI; typedef long long ll; ////////////////////////////////////////////////////// int main(){ ll A,B; scanf("%lld %lld",&A,&B); queue >Q; Q.push(MP(A,B)); while(!Q.empty()){ pair ab = Q.front(); Q.pop(); ll a = ab.fst; ll b = ab.snd; if ((a<0) or (b<0)) continue; if ((a==0) and (b==0)){ printf("Yes\n"); return 0; } if ((a%2 == 1) and (b%2 == 1)){ } else if (a%2 == 1){ Q.push(MP(a-1,b/2)); } else if (b%2 == 1){ Q.push(MP(a/2,b-1)); }else{ Q.push(MP(a-1,b/2)); Q.push(MP(a/2,b-1)); } } printf("No\n"); return 0; }