Problem:
 Score : 100 points    Problem Statement In AtCoder City, there are three stations numbered 1 , 2 , and 3 .  Each of these stations is operated by one of the two railway companies, A and B. A string S of length 3 represents which company operates each station. If S_i is A , Company A operates Station i ; if S_i is B , Company B operates Station i .  To improve the transportation condition, for each pair of a station operated by Company A and one operated by Company B, there will be a bus service connecting them.  Determine if there is a pair of stations that will be connected by a bus service.      Constraints  Each character of S is A or B .  |S| = 3         Input Input is given from Standard Input in the following format:  S       Output If there is a pair of stations that will be connected by a bus service, print Yes ; otherwise, print No .        Sample Input 1 ABA      Sample Output 1 Yes  Company A operates Station 1 and 3 , while Company B operates Station 2 .  There will be a bus service between Station 1 and 2 , and between Station 2 and 3 , so print Yes .       Sample Input 2 BBA      Sample Output 2 Yes  Company B operates Station 1 and 2 , while Company A operates Station 3 .  There will be a bus service between Station 1 and 3 , and between Station 2 and 3 , so print Yes .       Sample Input 3 BBB      Sample Output 3 No  Company B operates all the stations. Thus, there will be no bus service, so print No .

Solution (Python):
def main():
    ary = list(input())
    if ary.count(ary[0]) == 3:
        print('No')
    else:
        print('Yes')


if __name__ == '__main__':
    main()

Solution (Python):
S = list(input())

if (len(set(S)) == 1):
    ans = 'No'
else:
    ans = 'Yes'

print(ans)

Solution (Python):
s=input()
if s[0] == s[1] and s[1] == s[2]:
  print("No")
else:
  print("Yes")

Solution (Python):
a = input()

if a[0] == a[1] == a[2]:
  print('No')
else:
  print('Yes')

Solution (Python):
s = input()
pre = s[0]
for a in s[1:]:
  if pre != a:
    print("Yes")
    exit()
  pre = a
print("No")

Solution (Python):
S = input()
if S[0] == S[1] and S[1] == S[2]:
    print('No')
else:
    print('Yes')

Solution (Python):
a = str(input())
if a[0] == a[1] == a[2]:
    print('No')
else:
    print('Yes')

Solution (Python):
s = input()
if s == 'AAA' or s == 'BBB':
  print('No')
else:
  print('Yes')

Solution (Python):
s = input()
if s[0] != s[1]:
    print("Yes")
elif s[1] != s[2]:
    print("Yes")
else:
    print("No")

Solution (Python):
s = input()

a = s.count("A")
b = s.count("B")

if a==0 or b==0:
    print("No")
else:
    print("Yes")

Solution (Python):
s=input()
print('Yes' if 'A' in s and 'B' in s else 'No')

Solution (Python):
lis = input()

i = lis[0]
k = lis[1]
j = lis[2]

if i==j and j==k:
  print('No')
else:
  print('Yes')

Solution (Python):
s = input()

if s == "AAA" or s == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
S = str(input())
if S == 'AAA':
  print('No')
elif S == 'BBB':
  print('No')
else:
  print('Yes')

Solution (Python):
s=input()
if s=="AAA":
    print("No")
elif s=="BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()
if s[0] == "A" and s[1] == "A" and s[2] == "A":
    print("No")
elif s[0] == "B" and s[1] == "B" and s[2] == "B":
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()

ini = s[0]
for str in s:
    if str != ini:
        print("Yes")
        exit(0)
print("No")

Solution (Python):
s = list(input())
if len(set(s)) == 1:
    print("No")
else:
    print("Yes")

Solution (Python):
s=input()
t=[]
for i in s:
  t.append(i)
  
if len(set(t))==1:
  print("No")
else:
  print("Yes")

Solution (Python):
print("No" if len(set(input()))==1 else "Yes")

Solution (Python):
S = set(list(input()))
if len(S) == 2:
    print("Yes")
else:
    print("No")

Solution (Python):
S =input()
if S=="AAA" or S=="BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
S = input()

if S == "AAA" or S == "BBB":
  print("No")
else:
  print("Yes")

Solution (Python):
list_n = input()
list_n = list(list_n)
ans = "No"
for i in range(2):
    if list_n[i] != list_n[i+1]:
        ans = "Yes"

print(ans)

Solution (Python):
s = input()
if s =='AAA' or s=='BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
S=input()
import sys
for i in range(2):
  if S[i]==S[i+1]:
    continue
  else:
    print('Yes')
    sys.exit()
print('No')

Solution (Python):
s = input()

ans='Yes'
if s=='AAA': ans='No'
if s=='BBB': ans='No'

print(ans)

Solution (Python):
a,b,c=input()
if a=='A' and b=='A' and c =='A':
    print('No')
elif a=='B' and b=='B' and c =='B':
    print('No')
else:
    print('Yes')

Solution (Python):
s = input()

a = s.count('A')
b = s.count('B')

if a>0 and b>0:
    print('Yes')
else:
    print('No')

Solution (Python):
STR = input().split()
if STR ==["AAA"] or STR == ["BBB"]:
    print("No")
else:
    print("Yes")

Solution (Python):
S = str(input())
if S =='AAA' or S == 'BBB':
  print('No')
else:
  print('Yes')

Solution (Python):


S = input()

if S == "AAA" or S == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
n = input()
cnt = 0

for i in n:
    if i == "A":
        cnt += 1

if cnt == 1 or cnt == 2:
    print("Yes")
else:
    print("No")

Solution (Python):
S = input()
if S == "AAA" or S=="BBB":
  print("No")
else:
  print("Yes")

Solution (Python):
s=input()
if 'A' not in s or 'B' not in s:
  print('No')
else:
  print('Yes')

Solution (Python):
s = set(input())

if len(s) == 1:
	print("No")
else:
	print("Yes")

Solution (Python):
S = [x for x in input()]
if 'A' in S and 'B' in S:
    print("Yes")
else:
    print("No")

Solution (Python):
s = list(input())
if s[0] == "A" and s[1] == "A" and s[2] == "A":
    print("No")
elif s[0] == "B" and s[1] == "B" and s[2] == "B":
    print("No")
else:
    print("Yes")

Solution (Python):

A=list(input())

if A[0]==A[1]==A[2]:
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()
if len(set(s)) != 1:
    print('Yes')
else:
    print('No')

Solution (Python):
s = str(input())

if len(set(s)) == 1:
  print("No")
else:
  print("Yes")

Solution (Python):
s=list(input())
if all(i=="A" for i in s):
    print("No")
elif all(i=="B" for i in s):
    print("No")
else:
    print("Yes")

Solution (Python):
seq=input()
a=0
b=0
for i in range(3):
    if seq[i]=="A":
        a+=1
    else:
        b+=1
if a>=1 and b>=1:
    print("Yes")
else:
    print("No")

Solution (Python):
X = input()
a, b = 0, 0
for i in range(len(X)):
	if X[i] == "A":
		a += 1
	else:
		b += 1
if a == 3 or b == 3:
	print("No")
else:
	print("Yes")

Solution (Python):

s=input()

if s.count('A')==3 or s.count('B')==3:
    print('No')
else:
    print('Yes')

Solution (Python):
def resolve_a():
    s = input()
    if len(set(s)) == 1:
        print("No")
    else:
        print("Yes")
resolve_a()

Solution (Python):
s=input()

if (s == 'AAA') or (s == 'BBB'):
    print('No')
else:
    print('Yes')

Solution (Python):
x = str(input())

if 'AB' in x or 'BA' in x:
  print('Yes')
else:
  print('No')

Solution (Python):
S = input()

if 'A' in S and 'B' in S:
    print('Yes')
else:
    print('No')

Solution (Python):

import glob



REL_PATH = 'ABC\\158\\A'


TOP_PATH = 'C:\\AtCoder'

class Common:

    problem = []
    index = 0

    def __init__(self, rel_path):
        self.rel_path = rel_path

    def initialize(self, path):
        file = open(path)
        self.problem = file.readlines()
        self.index = 0
        return

    def input_data(self):
        try:
            IS_TEST
            self.index += 1
            return self.problem[self.index-1]

        except NameError:
            return input()

    def resolve(self):
        pass

    def exec_resolve(self):
        try:
            IS_TEST
            for path in glob.glob(TOP_PATH + '\\' + self.rel_path + '/*.txt'):
                print("Test: " + path)
                self.initialize(path)
                self.resolve()
                print("\n\n")
        except NameError:
            self.resolve()


class Solver(Common):

    def resolve(self):

        N = self.input_data()

        if "A" in N and "B" in N:
            print("Yes")
        else:
            print("No")


solver = Solver(REL_PATH)
solver.exec_resolve()

Solution (Python):
s = input()

if s == "AAA" or s == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
S = str(input())

if(S=='AAA' or S=='BBB'):
    print("No")
else:
    print("Yes")

Solution (Python):
S=input()
if(S[0]==S[1]) and (S[1]==S[2])and(S[0]==S[2]):
    print('No')
else:
    print('Yes')

Solution (Python):
if __name__ == '__main__':
    a = input()
    anum = 0

    for i in a:
        if i =="A":
            anum = anum +1

    if anum == 0 or anum ==3:
        print("No")
    else:
        print("Yes")

Solution (Python):
from sys import stdin


def main():
    S = stdin.readline().rstrip()
    if S == 'AAA' or S == 'BBB':
        print('No')
    else:
        print('Yes')


if __name__ == "__main__":
    main()

Solution (Python):
S = input()

if S == "AAA" or S == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
s = list(input())
t = set(s)
if len(t) == 1:
    print("No")
else:
    print("Yes")

Solution (Python):


import sys

DEBUG = False

def solve():
    return


def read_int_list(sep = " "):
    return [int(s) for s in sys.stdin.readline().rstrip().split(sep)]

def read_int():
    return int(sys.stdin.readline())

def dprint(*args, **kwargs):
    if DEBUG:
        print(*args, **kwargs)
    return


def main():
    chars = set(list(sys.stdin.readline().rstrip()))
    if len(chars) > 1:
        print("Yes")
    else:
        print("No")


if __name__ == "__main__":
    main()

Solution (Python):
s = list(input())
pre = s[0]
flag = True
for i in range(1, 3):
    if pre == s[i]:
        pass
    else:
        flag = False
    pre = s[i]
if flag:
    print("No")
else:
    print("Yes")

Solution (Python):


n = input()
if n == "AAA" or n == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()
if s[0] == s[1] and s[1] == s[2]:
    print('No')
else:
    print('Yes')

Solution (Python):
station = input()

if(station[0] == station[1] == station[2]):
  print("No")
else:
  print("Yes")

Solution (Python):
s=input()
print("Yes" if s.find("A")>=0 and s.find("B")>=0 else 'No')

Solution (Python):


import queue

def main():
    s = input()
    
    if s != 'AAA' and s != 'BBB':
        print('Yes')
    else:
        print('No')
if __name__ == '__main__':
    main()

Solution (Python):
def main():
    s = input()
    if s == 'AAA' or s== 'BBB':
        print('No')
    else:
        print('Yes')

if __name__ == '__main__':
    main()

Solution (Python):
import sys
read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines

def main():
    s = readline().strip()

    if s == "BBB" or s == "AAA":
        print("No")
    else:
        print("Yes")



if __name__ == "__main__":
    main()

Solution (Python):
S = input()
if 'A' in S and 'B' in S:
    print('Yes')
else:
    print('No')

Solution (Python):
s=input()
if s=='AAA':
    print('No')
elif s=='BBB':
    print('No')
else:
    print('Yes')

Solution (Python):



S=input()



if S[0]!=S[1]:
    print("Yes")
elif S[1]!=S[2]:
    print("Yes")
elif S[0]!=S[2]:
    print("Yes")
else:
    print("No")

Solution (Python):
def main():
    s = input()

    if 'A' in s and 'B' in s:
        print('Yes')
    else:
        print('No')

if __name__ == '__main__':
    main()

Solution (Python):
s = input()

if len(set(s)) == 1:
  print("No")
else:
  print("Yes")

Solution (Python):
S=input()
if S=='AAA' or S=='BBB':
    print ('No')
else:
    print ('Yes')

Solution (Python):
S = input()
if len(set(S)) == 2:
    print('Yes')
else:
    print('No')

Solution (Python):
S = input()
if S[0] == S[1] and S[1] == S[2]:
    print("No")
else:
    print("Yes")

Solution (Python):
s = str(input())
lists = list(s)

if len(set(lists)) == 1:
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()

def a(s):
    for i, s_i in enumerate(s):
        if s_i != s[i-1]:
            return 'Yes'

    return 'No'

print(a(s))

Solution (Python):
s=input()
flag=1
if s[0]=='A':
  for i in s:
    if i=='B':
      flag*=0
else:
  for i in s:
    if i=='A':
      flag*=0
if flag==0:
  print('Yes')
else:
  print('No')

Solution (Python):
import math

S=input()

if(S[0]==S[1] and S[0]==S[2]):
  print('No')
else:
  print('Yes')

Solution (Python):
s = input()
if s.count("A") == 0 or s.count("B") == 0:
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()
c = set(a for a in s)
if len(c) == 2:
  print("Yes")
else:
  print("No")

Solution (Python):
from sys import stdin
n = stdin.readline().rstrip()
if n == 'AAA' or n == 'BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
x=str(input())
if (x[0]!=x[1]) or (x[1]!=x[2]) or (x[0]!=x[2]):
    print("Yes")
else:
    print("No")

Solution (Python):

s = input()
l = []
for i in s:
    l.append(i)

s_len = set(l)

if len(s_len) == 2:
    print('Yes')
else:
    print('No')

Solution (Python):
s = list(input())
ans = "No"
prev = s[0]
for i in s[1:]:
    if i != prev:
        ans = "Yes"
        break
    prev = i
print(ans)

Solution (Python):

S = str(input())

print("Yes" if "A" in S and "B" in S else "No")

Solution (Python):
S = list(str(input()))
check = 0

for i in range(3):
  if S[i] == 'A':
    check += 1
    
if check == 0 or check == 3:
  print('No')
else:
  print('Yes')

Solution (Python):
S = input()
if ("A" in S and "B" in S):
  print("Yes")
else:
  print("No")

Solution (Python):
S = input()
if S == 'AAA' or S == 'BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
S=input()

if(S=="BBB" or S=="AAA"):
    print("No")
else:
    print("Yes")

Solution (Python):
N= input()
ans = "No"
pre = ""
for i in N:
    if i != pre and pre != "":
        ans = "Yes"
    pre = i
print(ans)

Solution (Python):
from sys import stdin

S = stdin.readline().rstrip().split()



if "AAA"==S[0]:
    print("No")
elif "BBB"==S[0]:
  	print("No")
else :
    print("Yes")

Solution (Python):
a = input()
ans = 'Yes'

if a == 'AAA' or a == 'BBB':
  ans = 'No'
  
print(ans)

Solution (Python):
s = input()
if len(set(s)) == 1:
    print('No')
else:
    print('Yes')

Solution (Python):
s = str(input())

if s == 'AAA' or s == 'BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
S = str(input())

if 'A' in S and 'B' in S:
    print('Yes')
else:
    print('No')

Solution (Python):
S = input()

print('No' if all(s == 'A' for s in S) or all(s == 'B' for s in S) else 'Yes')

Solution (Python):
S = list(input()) 
X = list(set(S))
if len(X)==1:
    print("No")
else:
    print("Yes")

Solution (Python):

S = input()
dic = {}

for s in S:
    dic[s] = 1


if len(dic) == 2:
    print('Yes')
else:
    print('No')

Solution (Python):
s = input()

a = s[0]
b = s[1]
c = s[2]

tmp = set([a,b,c])
if(len(tmp)==1):
    print('No')
else:
    print('Yes')

Solution (Python):
s=input()
flag=True
if s[0]==s[1]==s[2]:
    flag=False

print("Yes" if flag else "No")

Solution (Python):
s=input()
print("Yes" if "A" in s and "B" in s else "No")

Solution (Python):

import sys
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
read = sys.stdin.buffer.read
sys.setrecursionlimit(10 ** 7)

S = readline().strip().decode('utf-8')

if len(set(list(S))) == 1:
    print('No')
else:
    print('Yes')

Solution (Python):
data = input()

result = 'No'

if data.find('A') >= 0:
    if data.find('B') >= 0:
        result = 'Yes'

print(result)

Solution (Python):
s=input()
a=s[0]
b=s[1]
c=s[2]
if a== b and b==c:
	print("No")
else:
	print("Yes")

Solution (Python):
s=input()
if s=='AAA' or s=='BBB':
  print('No')
else:
  print('Yes')

Solution (Python):
s = list(input())
ans = set(s)
if len(ans) > 1:
  print('Yes')
else:
  print('No')

Solution (Python):
S= input()

if S=='AAA' or S=='BBB':
    print("No")
else:
    print("Yes")

Solution (Python):

S = input()


print("No" if S == "AAA" or S == "BBB" else "Yes")

Solution (Python):
s = input()

if s == 'AAA' or s == 'BBB':
  print("No")
else:
  print("Yes")

Solution (Python):
S=input()

pre=S[0]

ans='No'

for i in range(1,3):
    if S[i]!=pre:
        ans='Yes'
print(ans)

Solution (Python):
S = input()
if S[0] == S[1] and S[1] == S[2]:
    print("No")
else:
    print("Yes")

Solution (Python):
a=input()
if a == 'AAA' or a == 'BBB':
    print('No')
else:
    print('Yes')

Solution (Python):



'''
A=[]
B=[]
for i in range():
    a, b = map(int, input().split())
    A.append(a)
    B.append(b)'''




n = input()
if n=="AAA" or n=="BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
S = input()

if S[0] == S[1] == S[2]:
    print("No")
else:
    print("Yes")

Solution (Python):
S = input().strip()
if S[0]==S[1] and S[0]==S[2]:
  print("No")
else:
  print("Yes")

Solution (Python):
S = input()
if S in {'AAA', 'BBB'}:
    print('No')
else:
    print('Yes')

Solution (Python):
s = input()

sets = set(s)

if len(sets) > 1:
    print("Yes")
else:
    print("No")

Solution (Python):
import sys
input = sys.stdin.readline

S = input().rstrip('\r')
count = [0, 0]
for s in S:
    if (s == 'A'): count[0] = 1
    if (s == 'B'): count[1] = 1
if count[0] == 1 and count[1] == 1:
    print('Yes')
else:
    print('No')

Solution (Python):
N = list(input())
if N[0] == N[1] and N[1] == N[2]:
    print('No')
else:
    print("Yes")

Solution (Python):
a,b,c=[i for i in input()]

if a==b==c:
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()
if s == "BBB" or s == "AAA":
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()
if (s=='AAA')|(s=='BBB'):
    print('No')
else:
    print('Yes')

Solution (Python):
N = list(input())
F = True
for i in range(2):
    if N[i] != N[i+1]:
        F = False
if F:
    print("No")
else:
    print("Yes")

Solution (Python):
*s, = input()
print("Yes" if len(set(s)) == 2 else "No")

Solution (Python):
S = input()
if S[0] == S[1] == S[2]:
  print("No")
else:
  print("Yes")

Solution (Python):
s = input()

if (s[0]==s[1] and s[1]==s[2]):
    print("No")
else:
    print("Yes")

Solution (Python):
s = list(input(''))
if len(set(s)) == 1:
    print('No')
else:
    print('Yes')

Solution (Python):
s = list(input())


if len(list(set(s))) == 1:
  print("No")
else:
  print("Yes")

Solution (Python):
s = input()

company = s[0]
bus_needed = False
for i in range(1, len(s)):
    if company != s[i]:
        bus_needed = True
print("Yes" if bus_needed else "No")

Solution (Python):
s = input()

a = 0
b = 0
for x in s:
    if x == 'A':
        a += 1
    elif x == 'B':
        b += 1
if a == 3 or b == 3:
    print('No')
else:
    print('Yes')

Solution (Python):
s = input()
a_count = s.count('A')

if a_count == 0 or a_count == 3:
  print('No')
else:
  print('Yes')

Solution (Python):
L = list(input())
k = L.count("A")
if 0 < k < 3:
  print("Yes")
else:
  print("No")

Solution (Python):
S = input()
if S=='AAA' or S=='BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
def S(): return input().rstrip()

def main():
    s = S()

    if 'A' in s and 'B' in s:
        print('Yes')
    else:
        print('No')

if __name__ == '__main__':
    main()

Solution (Python):


S = input()

if S == 'AAA' or S == 'BBB':
    print('No')
else:
    print('Yes')

Solution (Python):



S = input()

Ns=len(S)
ans='Yes'
if S=='AAA' or S=='BBB':
    ans='No'

print(ans)

Solution (Python):




import sys




def main():
    S = input()

    res = 'Yes'

    if (S == 'AAA') or (S == 'BBB'):
        res = 'No'

    print(res)



main()

Solution (Python):
s=input()
if 'A' in s and 'B' in s:
  print('Yes')
else:
  print('No')

Solution (Python):
S = input()

if S=='AAA' or S=='BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
S = input()
if S == "AAA" or S == "BBB":
  print("No")
else:
  print("Yes")

Solution (Python):
import sys
import math
sys.setrecursionlimit(int(1e6))

S = input() 
if (S == 'AAA') or (S == 'BBB'):
    print('No')
else:
    print('Yes')

Solution (Python):
S = list(map(str,input()))
S_set = set(S)
print('Yes') if len(S_set) != 1 else print('No')

Solution (Python):
S=input()

SameFlag = False

if 'A' in S and 'B' in S:
    print('Yes')
else:
    print('No')

Solution (Python):
def main():
    S = list(input())
    s = set(S)
    if len(s) == 1:
        print('No')
    else:
        print('Yes')


if __name__ == '__main__':
    main()

Solution (Python):
s=set(input())
if(len(s)>1):
    print('Yes')
else:
    print('No')

Solution (Python):
S=input()
if 'A' in S and 'B' in S:
    print("Yes")
else:
    print("No")

Solution (Python):
s = set(input())
if(len(s) == 2):
    print('Yes')
else:
    print('No')

Solution (Python):
S=input()
if S[0]==S[1]==S[2]:
	print('No')
else:
	print('Yes')

Solution (Python):
S = input();

if(S != "AAA" and S != "BBB"):
  print("Yes")
else :
  print("No")

Solution (Python):
kanri = input()

if kanri == "AAA" or kanri == "BBB":
  print("No")
else:
  print("Yes")

Solution (Python):
S = input()

if S=='AAA' or S=='BBB':
    print('No')

else:
    print('Yes')

Solution (Python):
import sys
s = set(list(sys.stdin.readline().rstrip()))

if len(s) == 1:
    print('No')
else:
    print('Yes')

Solution (Python):
a = input()
if a[0] == a[1] == a[2]:
    print('No')
else:
    print('Yes')

Solution (Python):
s = input()
if s=='AAA' or s =='BBB':
    print('No')
else :
    print('Yes')

Solution (Python):
def main():
    s = input()

    if s == 'AAA' or s == 'BBB':
        print('No')
    else:
        print('Yes')

if __name__ == "__main__":
    main()

Solution (Python):
s = input()
if s[0]==s[1]==s[2]:
    print("No")
else:
    print("Yes")

Solution (Python):
import sys
import numpy as np



s = input()

if (s == "AAA") or (s == "BBB"):
    print("No")
else:
    print("Yes")

Solution (Python):
def main():
    n = input()
    if n[0] == "A" and n[1] =="A" and n[2] == "A":
        print("No")
    elif n[0] == "B" and n[1] =="B" and n[2] == "B":
        print("No")
    else:
        print("Yes")

if __name__ == '__main__':
    main()

Solution (Python):
s = list(input())
if 'A' in s and 'B' in s:
    print('Yes')
else:
    print('No')

Solution (Python):
S = input()

if S == "AAA" or S == "BBB":
  ans = "No"
else:
  ans = "Yes"
print(ans)

Solution (Python):

from sys import stdin
import sys

def getInputs():
	inputs=[]
	for line in stdin:
		line=line.split()
		inputs.append(line)
	return inputs


def main(inputs):
	s=inputs[0][0]
	if "A" in s and "B" in s:
		print("Yes")
		sys.exit(0)
	print("No")
			
		
	
	
	

if __name__=="__main__":
	inputs=getInputs()

	main(inputs)

Solution (Python):
S = input()

ans = True
if S.count('A') == 3 or S.count('B') == 3:
    ans = False

print('Yes' if ans else 'No')

Solution (Python):


s = input()

if s[0] == s[1] and s[1] == s[2]:
    print('No')
else:
    print('Yes')

Solution (Python):
if len(set(list(input()))) == 1:
    print('No')
else:
    print('Yes')

Solution (Python):
"""
A - Station and Bus
"""
abc = input()

if abc[0] == abc[1] == abc[2]:
    print("No")
else:
    print("Yes")

Solution (Python):
S = input()

if S == "AAA" or S == "BBB":
  print("No")
else:
  print("Yes")

Solution (Python):
S = input()
print("Yes" if S.count("A")*S.count("B") > 0 else "No")

Solution (Python):
S = list(input())

S = set(S)
if len(S) == 2:
    print("Yes")
else:
    print("No")

Solution (Python):
a,b,c = input()
if a==b==c:
  print('No')
 
else:
  print('Yes')

Solution (Python):

import sys

YES = "Yes"  
NO = "No"  


def solve(S: str):
    allA = [s=='A' for s in S]
    allB = [s=='B' for s in S]

    if all(allA) or all(allB):
        print(NO)
    else:
        print(YES)
    return



def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    S = next(tokens)  
    solve(S)

if __name__ == '__main__':
    main()

Solution (Python):
n = input()

if "A" in n and "B" in n:
    print("Yes")
else:
    print("No")

Solution (Python):
s = input()
if len(set(s)) == 1:
    print('No')
else:
    print('Yes')

Solution (Python):
S=str(input())
if S!='AAA' and S!='BBB':
  print('Yes')
else:
  print('No')

Solution (Python):
ls = set(input())
if len(ls) == 1:
    print('No')
else:
    print('Yes')

Solution (Python):
s=list(input())
flagS = s[0]
flag=0
for i in range(1,3):
  if flagS != s[i]:
    flag+=1
if flag==0:
  print("No")
else:
  print("Yes")

Solution (Python):


S=input()                                               

bl = 0
sh = ' '
for i in S:
	if sh != ' ' and sh != i:
		bl = 1
	sh = i

if bl == 0:
	print('No')
else:
	print('Yes')

Solution (Python):
S=input()

if S == 'AAA' or S == 'BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
S = input()

if(S == "AAA" or S == "BBB"):
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()
print("No" if all(map(lambda c: c == s[0], s)) else "Yes")

Solution (Python):


S = input()
if S == 'AAA' or S == 'BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
S = input()
sset = set()

for s in S:
    sset.add(s)
    
if len(sset) == 1:
    print('No')
elif len(sset) == 2:
    print('Yes')

Solution (Python):
s=input()

if s=='AAA' or s=='BBB':
    print('No')
else:
    print('Yes')

Solution (Python):

s = str(input())
if(s != 'AAA'):
    if(s != 'BBB'):
        print('Yes')
    else:
        print('No')
else:
    print('No')

Solution (Python):
S = input()

if S[0] != S[1] or S[1] != S[2] or S[0] != S[2]:
    print("Yes")
else:
    print("No")

Solution (Python):
def main():
    N= input()
    if N=="AAA" or N == "BBB":
        print("No")
    else:
        print("Yes")
    
main()

Solution (Python):
s = input()
print('No' if len(set(list(s))) == 1 else 'Yes')

Solution (Python):
a = input()
print('Yes' if a.count('A') >= 1 and a.count('B') >= 1 else 'No')

Solution (Python):
S = input()

len = len(set(S))

if len == 2:
    print('Yes')
else:
    print('No')

Solution (Python):
S = input()

flag = True
X = S[0]

for i in range(1, 3):
    if S[i] != X:
        flag = False
        
if flag:
    print("No")
else:
    print("Yes")

Solution (Python):
s = set(input())
print('Yes' if len(s) == 2 else 'No')

Solution (Python):
S = list(input())

if S[0] == S[1] and S[1] == S[2]:
  print("No")
else:
  print("Yes")

Solution (Python):
s = input()
print("No" if s=="AAA" or s=="BBB" else "Yes")

Solution (Python):
S = input()

if S == 'AAA':
    print('No')
elif S == 'BBB':
    print('No')
else:print('Yes')

Solution (Python):
S = input()

if S == 'AAA' or S == 'BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
if len(set(list(input()))) == 2:
  print("Yes")
else:
  print("No")

Solution (Python):
s = input()
print("Yes" if "A" in s and "B" in s else "No")

Solution (Python):
S = list(input())

if S[0] == S[1] == S[2]:
    print("No")
else:
    print("Yes")

Solution (Python):
S = input()

if("A" in S and "B" in S):
  print("Yes")
else:
  print("No")

Solution (Python):
s = input()
if s == "AAA" or s == "BBB":
  print("No")
else:
  print("Yes")

Solution (Python):
S = input()

if S == 'AAA' or S == 'BBB':
  print('No')
else:
  print('Yes')

Solution (Python):
s = input()
if s in ['A'*3, 'B'*3]:
    print('No')
else:
    print('Yes')

Solution (Python):
s = input()

if s[0]==s[1] and s[1]==s[2]:
    print('No')
else:
    print('Yes')

Solution (Python):
S=raw_input()
if "A" in S and "B" in S: 
    print "Yes" 
else:
    print "No"

Solution (Python):

 
import math
import itertools
import sys
import copy

 





S = str(input())

if S[0] == S[1] and S[1] == S[2] :
  print ("No")
else :
  print ("Yes")

Solution (Python):
S = input()
if S[1] == S[2] == S[0]:
  print("No")
else:
  print("Yes")

Solution (Python):
s = input()
if s == 'AAA' or s == 'BBB':
    print('No')
else:
    print('Yes')

Solution (Python):
S = input()
if 'A' in S and 'B' in S:
  print('Yes')
else:
  print('No')

Solution (Python):




a = input()


if a[0] == a[1] and a[1] == a[2]:
    ans = "No"
else:
    ans = "Yes"


print(ans)

Solution (Python):
s=input()
if s=="AAA":
    print("No")
elif s=="BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()

if s == "AAA" or s == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
import numpy as np
S = str(input().split())

if ('A' in S) & ('B' in S):
    print('Yes')
else:
    print('No')

Solution (Python):
s = input()

if s == "AAA" or s == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
S = input()
s_list = [i for i in S]
s_set = set(s_list)
if len(s_set) == 1:
    print('No')
else:
    print('Yes')

Solution (Python):
S=input()

if(S.count('A')==3 or S.count('B')==3):
    print("No")
else:
    print("Yes")

Solution (Python):
S = input()
if "A" in S and "B" in S:
    print("Yes")
else:
    print("No")

Solution (Python):
import sys

sys.setrecursionlimit(10 ** 6)
int1 = lambda x: int(x) - 1
p2D = lambda x: print(*x, sep="\n")
def II(): return int(sys.stdin.readline())
def MI(): return map(int, sys.stdin.readline().split())
def LI(): return list(map(int, sys.stdin.readline().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]
def SI(): return sys.stdin.readline()[:-1]

def main():
    s=SI()
    if s=="AAA" or s=="BBB":print("No")
    else:print("Yes")

main()

Solution (Python):
s = input()
if 'A' in s and 'B' in s:
    print('Yes')
else:
    print('No')

Solution (Python):
N = list(input())
a = N.count('A')
if a == 1 or a == 2:
    print('Yes')
else:
    print('No')

Solution (Python):
S = input()

if S == "AAA" or S =="BBB":
  print("No")
else:
  print("Yes")

Solution (Python):
S = set(input())
print('Yes') if len(S) == 2 else print('No')

Solution (Python):
a=input()
if "AB" in a or "BA" in a:
    print("Yes")
else:
    print("No")

Solution (Python):
s = input()

if len(s) == s.count("A") or len(s) == s.count("B"):
  print("No")
else:
  print("Yes")

Solution (Python):
n = input()
if (n[0]=='A' and n[1]=='A' and n[2]=='A') or(n[0]=='B' and n[1]=='B' and n[2]=='B')  :
  print('No')
else:
  print("Yes")

Solution (Python):
s = input()

if 'A' in s and 'B' in s:
    print('Yes')
else:
    print('No')

Solution (Python):
def main():
	s=input()
	if s=='AAA' or s=='BBB':
		print('No')
	else:
		print('Yes')
main()

Solution (Python):
s = input().strip()

if s[0] == s[1] == s[2]:
    print("No")
else:
    print("Yes")

Solution (Python):



def judge(s):
    return s != "AAA" and s != "BBB"


def main():
    s = input()
    print("Yes" if judge(s) else "No")


if __name__ == "__main__":
    main()

Solution (Python):
str = input()
if (str=="AAA") or (str=="BBB"):
  print("No")
else:
  print("Yes")

Solution (Python):
import sys
input = sys.stdin.readline

s = input().strip()

def cond():
    if s == 'AAA' or s == 'BBB':
        return False
    else:
        return True

if cond():
    print('Yes')
else:
    print('No')

Solution (Python):
def main():
    from collections import Counter

    n = list(str((input())))
    dic = Counter(n)
    if len(dic) == 1:
        print("No")
    else:
        print("Yes")


if __name__ == "__main__":
    main()

Solution (Python):
S=input()
if 'A' in S and 'B' in S:
    print("Yes")
else:
    print("No")

Solution (Python):
a = input()
if(a == "AAA" or a == "BBB"):
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()
if "AB" in s or "BA" in s:
    print("Yes")
else:
    print("No")

Solution (Python):
s = input()
print("No" if s=='AAA' or s== 'BBB' else "Yes")

Solution (Python):
s=input()
if s=="AAA" or s=="BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
S = str(input())
if S == "AAA" or S == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
S=set(input())
print("Yes" if len(S)==2 else "No")