#include #include #include #include #define lli long long using namespace std; int main() { // freopen("input_files/inp7.txt", "r", stdin); // freopen("output_files/out7.txt", "w", stdout); int t; lli n,m; cin >> t; assert(t >= 1 && t <= 100000); while ( t-- ) { cin >> n >> m; assert(n >= 1 && n <= 1000000000000000000LL); assert(m >= 1 && m <= 1000000000000000000LL); if ( (n == 1 && m > 3) || (m == 1 && n > 3 ) ) puts("No"); else if ( n%2 == 1 && m%2 == 1 ) puts("No"); else puts("Yes"); } return 0; }