import java.util.Scanner; public class Knightwalk { public static void main(String[] args) { // TODO 自動生成されたメソッド・スタブ Scanner s = new Scanner(System.in); int X = Math.abs(s.nextInt()),Y = Math.abs(s.nextInt()); s.close(); if(X > 6 || Y > 6){ System.out.println("NO"); }else{ int A = Math.max(X, Y); int count = 0; while(A >= 2){ count++; A -= 2; } if(Math.min(X, Y) == count + (A % 2) * 2){ System.out.println("YES"); }else{ System.out.println("NO"); } } } }