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):

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 = str(input())
if S == "BBB":
    print("No")
elif S == "AAA":
    print("No")
else:
    print("Yes")

Solution (Python):
s = input()
if (s.find("A") != -1) and (s.find("B") != -1):
    print("Yes")
else:
    print("No")

Solution (Python):
S = input()

answer = "No"

if not (S[0] == S[1] and S[1] == S[2] and S[0] == S[2]):
    answer = "Yes"

print(answer)

Solution (Python):
S = list(map(str, input()))
if S[0] == S[1] and S[1] ==S[2] and 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 s=="AAA":
    print("No")
elif s=="BBB":
    print("No")
else:
    print("Yes")

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':
  print('No')
else:
  print('Yes')

Solution (Python):
S=input()
L=[S[0],S[1],S[2]]
SS=set(L)
ans=len(SS)
if ans==2:
  print('Yes')
else:
  print('No')

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

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

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

Solution (Python):

S=list(input())

if S[0]==S[1]==S[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 == '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):
S = input()
if S == "AAA" or S == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):

str = input()

answer = "No"
if 'B' in str and 'A' in str:
  answer = "Yes"
  
print(answer)

Solution (Python):

s = input()
if 'AB' in s or 'BA' in s:
    print('Yes')
else:
    print('No')

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

Solution (Python):
tmp = ""

for s in list(input()):
    if tmp == "":
        tmp = s
        continue
    if tmp != s:
        print("Yes")
        exit()

print("No")

Solution (Python):
s = input()

x = set(s)
if len(x) ==1:
  print("No")
elif len(x) ==2:
  print("Yes")

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

Solution (Python):
S = input()

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

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

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

Solution (Python):

 
 
def main():
 
    in_data = input()
 
    if (in_data == 'AAA' or
        in_data == 'BBB'):
        print('No')
    else:
        print('Yes')
 
    return 0
 
 
if __name__ == '__main__':
    main()

Solution (Python):
S = input()

if len(S)==3 and S.count('A')==2 or S.count('B')==2:
    print('Yes')

else:
    print('No')

Solution (Python):

"""
Created on Sun Jan 19 20:52:57 2020

@author: over-
"""


S=input()

ans='No'

if S!='AAA' and S!='BBB': ans='Yes'

print(ans)

Solution (Python):
S = input()
n = len(S)
if n == 3:
  a = S.split()
  x = S[0]
  y = S[1]
  z = S[2]
  if x != y or y != z:
    print("Yes")
  else:
    print("No")

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

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

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

print("Yes" if len(s)>1 else "No")

Solution (Python):
a = list(input())
A_flag = False
B_flag = False

for n in range(3) :
    if a[n] == "A":
        A_flag = True
    elif a[n] == "B":
        B_flag = True
if A_flag and B_flag:
    print("Yes")
else:
    print("No")

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

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

Solution (Python):
S = input()

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

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

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

Solution (Python):


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


if __name__ == "__main__":
    solve()

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

Solution (Python):
def main():
    s = input()
    exists = s != "AAA" and s != "BBB"
    return "Yes" if exists else "No"
    


if __name__ == "__main__":
    print(main())

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

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

Solution (Python):
S = input()

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

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


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 "A" in S and "B" in S:
    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 'A' in S and 'B' in S:
  print('Yes')
else:
  print('No')

Solution (Python):
SSS = input()
KKK = "No"
NNN = []
NNN = list(SSS)
if NNN[0] != NNN[1] or NNN[0] != NNN[2]:
    KKK = "Yes"
print(KKK)

Solution (Python):
S = input()

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

Solution (Python):
S = input()
if len(S)==3 and S.count('A')==2 or S.count('B')==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())
if s == "AAA" or s == "BBB":
    print("No")
else:
    print("Yes")

Solution (Python):
s = list(input())
if len(set(s)) !=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()
if S == "AAA" or S =="BBB":
    print('No')
else:
    print('Yes')

Solution (Python):
from collections import defaultdict, deque, Counter
from heapq import heappush, heappop, heapify
import math
import bisect
import random
from itertools import permutations, accumulate, combinations, product
import sys
import string
from bisect import bisect_left, bisect_right
from math import factorial, ceil, floor
from operator import mul
from functools import reduce
import pprint
sys.setrecursionlimit(10 ** 9)


INF = 10 ** 20
def LI(): return list(map(int, sys.stdin.buffer.readline().split()))
def I(): return int(sys.stdin.buffer.readline())
def LS(): return sys.stdin.buffer.readline().rstrip().decode('utf-8').split()
def S(): return sys.stdin.buffer.readline().rstrip().decode('utf-8')
def IR(n): return [I() for i in range(n)]
def LIR(n): return [LI() for i in range(n)]
def SR(n): return [S() for i in range(n)]
def LSR(n): return [LS() for i in range(n)]
def SRL(n): return [list(S()) for i in range(n)]
def MSRL(n): return [[int(j) for j in list(S())] for i in range(n)]
mod = 1000000007

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

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

Solution (Python):
S=input()
print(("No","Yes")[len(set(S))>1])

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

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

Solution (Python):
A = input()

if A in ['AAA', 'BBB']:
    print('No')
else:
    print('Yes')

Solution (Python):
S = input()
if len(S)==3 and S.count('A')==2 or S.count('B')==2:
    print("Yes")
else:
    print("No")

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

c = S[0]
d = S[1]
e = S[2]

if c == d == e:
    print("No")
else:
    print("Yes")

Solution (Python):
s = set(list(str(input())))
if len(s) == 1:
    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 len(set(S)) == 1:
    print("No")
else:
    print("Yes")

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

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

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

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

Solution (Python):

s = input()

cntA = 0
cntB = 0

for i in s:
    if i == 'A':
        cntA += 1

    else:
        cntB += 1

if cntA == 3 or cntB == 3:
    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()
if len(S)==3 and S.count('A')==2 or S.count('B')==2:
    print('Yes')
else:
    print('No')

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

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

Solution (Python):

import sys

YES = "Yes"  
NO = "No"  


def solve(S: str):
    if S=='AAA' or S=='BBB':
        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):
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):
S = input()
if S == "AAA" or S == "BBB":
  print("No")
else:
  print("Yes")

Solution (Python):
S = input()

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

Solution (Python):
1.
S = input()

if len(S)==3 and S.count('A')==2 or S.count('B')==2:
    print('Yes')

else:
    print('No')

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

Solution (Python):
S = list(input())
if S.count('A')==3 or S.count('B')==3:
    print('No')
else:
    print('Yes')

Solution (Python):


a,b,c=input()

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

Solution (Python):
def solve():
    N = input()
    
    if not 'A' in N or not 'B' in N:
        return 'No'

    return 'Yes'

print(solve())

Solution (Python):
s=input().strip()
if "A" not in s:
    print("No")
elif "B" not in s:
    print("No")
else:
    print("Yes")

Solution (Python):
import sys

s = list(input())
if s[0] == 'A' and s[1] == 'A' and s[2] == 'A':
  print('No')
  sys.exit()
if s[0] == 'B' and s[1] == 'B' and s[2] == 'B':
  print('No')
  sys.exit()
print('Yes')

Solution (Python):
a = input()

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

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

Solution (Python):
import collections
S = input()


c = collections.Counter(list(S))

if len(c.keys()) >= 2:
    print("Yes")
else:
    print("No")

Solution (Python):
import sys

s = list(input())
if s[0] == 'A' and s[1] == 'A' and s[2] == 'A':
  print('No')
  sys.exit()
if s[0] == 'B' and s[1] == 'B' and s[2] == 'B':
  print('No')
  sys.exit()
print('Yes')

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


a_flg = 0
b_flg = 0
i = 0
while i < 3:
  if (S_list[i] == "A"):
    a_flg = 1
  else:
    b_flg = 1
  i += 1

if (a_flg == 1 and b_flg ==1):
  print("Yes")
else:
  print("No")

Solution (Python):
S = input()
if len(S)==3 and S.count('A')==2 or S.count('B')==2:
  print('Yes')
else:
  print('No')

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

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

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

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

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

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

Solution (Python):
data = input()
if (data.count("A") == 3) or (data.count("B") == 3):
    ans = "No"
else:
    ans = "Yes"
print(ans)

Solution (Python):
s1, s2, s3 = input()
count = 0
if s1 != s2:
    count += 1
if s2 != s3:
    count += 1
if s1 != s3:
    count += 1
if count == 0:
    print('No')
else:
    print('Yes')

Solution (Python):



s=input()

if (s[1] != s[0] or s[1] != 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()
print(['No','Yes'][S.find("B") != -1 and S.find("A") != -1])

Solution (Python):



S = input()

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

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

Solution (Python):

def main():
    S = input()

    flag = False
    for i in range(2):
        tmp = S[i]
        if tmp != S[i+1]:
            flag = True
    if flag : print("Yes")
    else: print("No")

if __name__ == "__main__":
    main()

Solution (Python):



S = input()







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

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

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

Solution (Python):
i=input()
j=i[0]
k=0

for n in range(2):
	if i[n+1]!=i[0]:
		k=1
if k==0:
	print('No')
else:
	print('Yes')

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

Solution (Python):
InpStr=str(input())
result='Yes'

if InpStr[0]=='A' and InpStr[1]=='A' and InpStr[2]=='A':
    result='No'

if InpStr[0]=='B' and InpStr[1]=='B' and InpStr[2]=='B':
    result='No'

print(result)

Solution (Python):




lst = input().split()


one = lst[0][0]
two = lst[0][1]
three = lst[0][2]



one_two = one != two
two_three = two != three
three_one = three != one



any([one_two, two_three, three_one])



if any([one_two, two_three, three_one]):
    print('Yes')
else:
    print('No')

Solution (Python):
S=input()
a=1
if S[0] == 'A':
    if S[1] == 'A':
        if S[2] == 'A':
            a = 0
if S[0] == 'B':
    if S[1] == 'B':
        if S[2] == 'B':
            a = 0

if a == 0:
    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[0]==s[1]==s[2]:
    print("No")
else:
    print("Yes")

Solution (Python):
A = "AAA"
B = "BBB"
S = input()
if A in S or B in S:
    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))==1:
    print('No')
else:print('Yes')

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

Solution (Python):
char = input()
bool1 = "AB" in char
bool2 = "BA" in char

if bool1 or bool2:
  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 = str(input())
if s.count('A') == 1:
    print("Yes")
elif s.count('A') == 2:
    print("Yes")
else:
    print("No")

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

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

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

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

Solution (Python):
S = input()
A,B = 0,0
for s in S:
    if s == 'A':
        A += 1
    else:
        B += 1

if A != 0 and B != 0:
    print('Yes')
else:
    print('No')

Solution (Python):
a,b,c=input()

List = []
List.append(a)
List.append(b)
List.append(c)

for i in range(0,2):
    if List[i] != List[i + 1]:
        print('Yes')
        exit()

print('No')

Solution (Python):
s = list(input())
if (s == ['A', 'A', 'A']) or (s == ['B', 'B', 'B']):
    print('No')
else:
    print('Yes')

Solution (Python):
s = input()

ss = s[0]

if ss == "A":
  if "B" in s:
    print("Yes")
  else:
    print("No")
else:
  if "A" in s:
    print("Yes")
  else:
    print("No")

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

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

Solution (Python):
S = input()

zikkou= [0,2]

isto = True

for n in zikkou:
    if S.count("A") == 3 or S.count("B") == 3:
        isto = False


if isto:
    print("Yes")
else:
    print("No")

Solution (Python):
S = str(input())
print( "No\n" if (ord(S[0]) + ord(S[1]) + ord(S[2]) == ord(S[0])*3) else "Yes\n")

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

s = input()

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

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

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

Solution (Python):
s=str(input())
l=[]
for i in range(3):
  l.append(s[i])
if len(set(l))==1:
  print('No')
else:
  print('Yes')

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

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

Solution (Python):
a=input()
len=len(a)
a_cnt=0
b_cnt=0
for i in range(len):
    if a[i]=='A':
        a_cnt+=1
    else :
        b_cnt+=1
if a_cnt>0 and b_cnt>0:
    print('Yes')
else :
    print('No')

Solution (Python):
bus = input()
if bus == ("AAA"):
  print ("No")
elif bus == ("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):

S = input()

if len(S)==3 and S.count('A')==2 or S.count('B')==2:
    print('Yes')

else:
    print('No')

Solution (Python):


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

Solution (Python):
input_line = input()

if input_line == 'ABB' or input_line == 'BAB' or input_line == 'BBA' or input_line == 'BAA' or input_line == 'ABA' or input_line == 'AAB':
  print('Yes')
else:
  print('No')

Solution (Python):
input_line = input()

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

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

print(Ans)

Solution (Python):
s = str(input())
a = 0
for i in s:
  if i == "A":
    a += 1
  elif i == "B":
    a -= 1
if a == 3 or a == -3:
  print("No")
else:
  print("Yes")

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

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

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

s = readline().rstrip().decode('utf-8')

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

Solution (Python):
import math
import sys


S = input()

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

Solution (Python):
def map_all(es):
    return all([e == es[0] for e in es[1:]]) if es else False

a =input()
aa = list(a)

if map_all(aa):
  print('No')
else:
  print('Yes')

Solution (Python):
station = input()
a = False
b = False
for i in station:
    if i == 'A':
        a = True
    if i == 'B':
        b = True

if a and b:
    print("Yes")
else:
    print("No")

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

if len(set(S)) == 1:
    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 len(set(S)) == 1:
    print('No')
else:
    print('Yes')

Solution (Python):
S = list(input())
now = S[0]
ans = False
for i in range(1,len(S),1):
    if S[i] != now :
        ans = True
if ans :
    print("Yes")
else:
    print("No")

Solution (Python):
bus = input()
kazu_a = bus.count('A')

if kazu_a == 3:
    answer = 'No'
elif kazu_a == 0:
    answer = 'No'
else:
    answer = 'Yes'

print(answer)

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

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

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

Solution (Python):


a = input()

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

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

if S[0]!=S[1] or S[1]!=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[0] == S[1] and S[1] == S[2]:
  print('No')
else:
  print('Yes')

Solution (Python):
import argparse

def main(s: str):
    if s[0] == s[1] == s[2]:
        return "No"
    else:
        return "Yes"

if __name__ == "__main__":
    s = input()
    print(main(s))

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

Solution (Python):
def Main(S):
    return 'No' if S == 'AAA' or S == 'BBB' else 'Yes'

def main():
    S = str(input())
    print(Main(S))

if __name__ == '__main__':
    main()

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

result = "Yes" if "A" in s and "B" in s else "No"

print(result)

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

Solution (Python):
abc=str(input())
a=abc[0]
b=abc[1]
c=abc[2]



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

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

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

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

Solution (Python):

import collections


class Solution:
    def solve(self, string):
        counts = collections.Counter(string)

        return counts["A"] and counts["B"]


sol = Solution()

string = input().strip()

print("Yes" if sol.solve(string) else "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):
p, q, r = list(input())
if p == q == r :
    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] == s[1] and s[1] == s[2]:
    print('No')
else:
    print('Yes')

Solution (Python):
s = input()

a = False
for i in range(len(s)):
    if s[i] == "A":
        a = True
        break

b = False
for i in range(len(s)):
    if s[i] == "B":
        b = True
        break

if a and b:
    print("Yes")
else:
    print("No")

Solution (Python):
s = input()
a = int(s.count("A"))
b = int(s.count("B"))

if a == 3 or b == 3:
    print("No")

else:
    print("Yes")

Solution (Python):

import sys
sys.setrecursionlimit(10000000)
INF = 1<<32

YES = "Yes"  
NO = "No"  

def solve(S: str):
    if S.count('A') == 3 or S.count('B') == 3:
        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):
s = input()
cnt = 0
for i in range(1, len(s)):
    if s[i] != s[i-1]:
        cnt += 1

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

Solution (Python):
S = input()
s = {}

for i in S:
    s[i] = 1

if len(s.keys()) > 1:
    print("Yes")
else:
    print("No")

Solution (Python):
s = input()
for i in range(2):
	if s[i] != s[i+1]:
		print("Yes")
		exit()
print("No")

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

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

    if S[0] == S[1] and S[0] == S[2]:

        print("No")
    else :
        print("Yes")


main()

Solution (Python):
inp = input()
if inp == "AAA" or inp == "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):
def resolve():
    s = input()
    c = set()

    for cha in s:
        c.add(cha)

    if len(c) == 1:
        print('No')

    else:
        print('Yes')

resolve()

Solution (Python):
import sys

input = sys.stdin.readline

S = input().strip()

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

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

Solution (Python):
S = list(input())
s_A = [s for s in S if 'A' in s]
s_B = [s for s in S if 'B' in s]

if len(s_A) == 3 or len(s_B) == 3:
    ans = 'No'
else:
    ans = 'Yes'

print(ans)

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()
d = {"A":0,"B":0}
for i in s:
	d[i] += 1
if (d["A"] == 2 and d["B"] == 1) or (d["A"] == 1 and d["B"] == 2):
	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 = input()

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

Solution (Python):
def a(s):
 
    return "Yes" if s.count("A") != 0 and s.count("B") != 0 else "No"
 
 
def main():
    s = str(input())
    print(a(s))
 
if __name__ == '__main__':
    main()

Solution (Python):
a = input()
if a[0] == a[1] and 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()
flag = 0
for i in range(2):
	if S[i] == S[i+1]:
		pass
	else:
		flag = flag +1

if flag >= 1:
	print("Yes")
else:
	print("No")

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

print("No" if len(S) == 1 else "Yes")

Solution (Python):
s = input()

if s.count('A')>0 and s.count('B')>0:
    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 == '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 = set(list(input()))

print("Yes") if len(s) == 2 else print("No")

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

Solution (Python):
a = input()
if a[0]==a[1] and a[0]==a[2]:
  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 main():
 
    in_data = input()
 
    if (in_data == 'AAA' or
        in_data == 'BBB'):
        print('No')
    else:
        print('Yes')
 
    return 0
  
  
if __name__ == '__main__':
    main()

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

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

Solution (Python):
s = input()

a = s[0]
if a == s[1] and a == s[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] or s[1]!=s[2]:
    print('Yes')
else:
    print('No')

Solution (Python):
strStation = input()

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

Solution (Python):
S = list(input())
ans ="No"
for i in range(3):
  if S[i] != S[(i+1)%3]:
    ans = "Yes"
print(ans)

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

if s[0] == s[1] and s[1] == s[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():
  p = input()
  if p[0] == p[1] == p[2]:
    return 'No'
  else:
    return 'Yes'
  

print(main())

Solution (Python):
S = input()

s1 = S[0]
s2 = S[1]
s3 = S[2]

if s1 == s2 and s2 == s3 and s3 == s1:
    print('No')
else:
    print('Yes')

Solution (Python):

s = input()
s1 = s[0]
s2 = s[1]
s3 = s[2]

if s1==s2:
	if s1==s3:
		print("No")
	else:
		print("Yes")
else:
	print("Yes")

Solution (Python):
a = input()

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

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

Solution (Python):
S = input()

if len(S)==3 and S.count('A')==2 or S.count('B')==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()
l = list(s)

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

Solution (Python):
s = input()
a = s.count("A")
b = s.count("B")
if a == 3 or b == 3:
  print('No')
else:
  print('Yes')