import java.util.*;

public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String a = sc.next();
		boolean check = a.contains("A") && a.contains("B");
		System.out.println(check ? "Yes" : "No");
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String a = sc.next();
		boolean check = a.contains("A") && a.contains("B");
		System.out.println(check ? "Yes" : "No");
	}
} Main public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String a = sc.next();
		boolean check = a.contains("A") && a.contains("B");
		System.out.println(check ? "Yes" : "No");
	} main {
		Scanner sc = new Scanner(System.in);
		String a = sc.next();
		boolean check = a.contains("A") && a.contains("B");
		System.out.println(check ? "Yes" : "No");
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) String a = sc.next(); a sc.next() sc.next sc boolean check = a.contains("A") && a.contains("B"); check a.contains("A") && a.contains("B") a.contains("A") a.contains a "A" a.contains("B") a.contains a "B" System.out.println(check ? "Yes" : "No") System.out.println System.out System System.out check ? "Yes" : "No" check "Yes" "No" String[] args args public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String a = sc.next();
		boolean check = a.contains("A") && a.contains("B");
		System.out.println(check ? "Yes" : "No");
	}
} public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String a = sc.next();
		boolean check = a.contains("A") && a.contains("B");
		System.out.println(check ? "Yes" : "No");
	}
} Main
import java.util.*;

public class Main {
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		String a = sc.next();
		boolean check = a.contains("A") && a.contains("B");
		System.out.println(check ? "Yes" : "No");
	}
}
