#include #include #include using namespace std; class range {private: struct I{int x;int operator*(){return x;}bool operator!=(I& lhs){return x dx = {2, 2, 1, 1, -1, -1, -2, -2}, dy = {1, -1, 2, -2, 2, -2, 1, -1}; bool nya(int x, int y, int times) { queue que; que.push(Point({x, y, times})); while(!que.empty()) { Point cur = que.front(); que.pop(); if(cur.c < 0) { continue; } if(cur.x == 0 && cur.y == 0) { return true; } for(int i : range(dx.size())) { int nx = cur.x + dx[i], ny = cur.y + dy[i], nc = cur.c - 1; que.push(Point({nx, ny, nc})); } } return false; } int main(void) { int x, y; scanf("%d%d", &x, &y); puts(nya(x, y, 3) ? "YES" : "NO"); return 0; }