import java.util.*; public class Main { public static void main(String[] args) throws Exception { Scanner sc = new Scanner(System.in); long a = sc.nextLong(); long b = sc.nextLong(); while(a > 0 || b > 0){ if(a % 2 == 1 && b % 2 != 1){ System.out.println("No"); return; } a = a / 2; b = b / 2; } System.out.println("Yes"); } }