S = {(0,0)} D = [(2,1),(1,2),(-1,2),(-2,1),(-2,-1),(-1,-2),(1,-2),(2,-1)] for i in range(3): for x,y in list(S): for dx,dy in D: S.add((x+dx,y+dy)) X,Y = map(int,input().split()) if (X,Y) in S: print("YES") else: print("NO")