#include using namespace std; using ll = long long; int main(){ int a,b; cin >> a >> b; if(a == b || (a==2 && b==4) || (a==4 && b==2)) cout << "Yes" << endl; else cout << "No" << endl; return 0; }