import java.util.*;

class Main {
	Scanner sc;
	String S;
	
	private void calc() {
		sc = new Scanner(System.in);
		S = sc.next();
		
		if (S.equals("AAA") || S.equals("BBB")) System.out.println("No");
		else System.out.println("Yes");
	}

	public static void main(String[] args) {
		new Main().calc();
	}
} import java.util.*; util.* java class Main {
	Scanner sc;
	String S;
	
	private void calc() {
		sc = new Scanner(System.in);
		S = sc.next();
		
		if (S.equals("AAA") || S.equals("BBB")) System.out.println("No");
		else System.out.println("Yes");
	}

	public static void main(String[] args) {
		new Main().calc();
	}
} Main Scanner sc; sc String S; S private void calc() {
		sc = new Scanner(System.in);
		S = sc.next();
		
		if (S.equals("AAA") || S.equals("BBB")) System.out.println("No");
		else System.out.println("Yes");
	} calc {
		sc = new Scanner(System.in);
		S = sc.next();
		
		if (S.equals("AAA") || S.equals("BBB")) System.out.println("No");
		else System.out.println("Yes");
	} sc = new Scanner(System.in) sc new Scanner(System.in) S = sc.next() S sc.next() sc.next sc if (S.equals("AAA") || S.equals("BBB")) System.out.println("No");
		else System.out.println("Yes"); S.equals("AAA") || S.equals("BBB") S.equals("AAA") S.equals S "AAA" S.equals("BBB") S.equals S "BBB" System.out.println("No") System.out.println System.out System System.out "No" System.out.println("Yes") System.out.println System.out System System.out "Yes" public static void main(String[] args) {
		new Main().calc();
	} main {
		new Main().calc();
	} new Main().calc() new Main().calc new Main() String[] args args
import java.util.*;

class Main {
	Scanner sc;
	String S;
	
	private void calc() {
		sc = new Scanner(System.in);
		S = sc.next();
		
		if (S.equals("AAA") || S.equals("BBB")) System.out.println("No");
		else System.out.println("Yes");
	}

	public static void main(String[] args) {
		new Main().calc();
	}
}
