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

Solution (Python):
S = input()
flag = False
for i in range(len(S)):
  if S[i] != S[0]:
    flag = True
if flag == True:
  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 = input()
if S == "AAA":
    print("No")
elif S == "BBB":
    print("No")
else:
    print("Yes")

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

Solution (Python):
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):
def yesno(S):
  if S=="AAA" or S=="BBB":
    return "No"
  else:
    return "Yes"
  
S=input()
print(yesno(S))

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

S=input()
print(yesno(S))

Solution (Python):
import sys


def solve():
    input = sys.stdin.readline
    mod = 10 ** 9 + 7
    s = str(input().rstrip('\n'))
    if s[0] != s[1] or s[0] != s[2] or s[1] != s[2]:
        print("Yes")
    else:
        print("No")


if __name__ == '__main__':
    solve()

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 = str(input())

cnt1=0
cnt2=0
for i in S:
    if i=='A':
        cnt1+=1
    else:
        cnt2+=1
if cnt1>=1 and cnt2>=1:
    print('Yes')
else:
    print('No')

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

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

Solution (Python):
t=input()
if 'AAA' in t or 'BBB' in t:
    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()
S=[1 if s=='A' else 0 for s in S]
print("No") if sum(S)==0 or sum(S)==3 else print("Yes")

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

Solution (Python):
def main():
    char = input()
    count = 0
    chars_set = set()
    for c in char:
        if c not in chars_set:
            chars_set.add(c)
    if len(chars_set) > 1:
        print("Yes")
        return
    print("No")


if __name__ == "__main__":
    main()

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

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

Solution (Python):

S = input()


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

Solution (Python):
print('YNeos'[len(set(input()))==1::2])

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 sys import stdin, stderr

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

   return 0

if __name__ == '__main__': main()

Solution (Python):
s = input()

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

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

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

Solution (Python):
if len(set(input())) == 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):
stations = input()
numA = 0
numB = 0
for station in stations:
    if station == 'A':
        numA +=1
    else:
        numB += 1
if (numA > 2 or numB > 2):
    print('No')
else:
    print('Yes')

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

if len(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 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] 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):
str = input()
count_A = str.count('A')
count_B = str.count('B')
if count_A > 0 and count_B > 0:
  print('Yes')
else :
  print("No")

Solution (Python):
str = input()
count_A = str.count('A')
count_B = str.count('B')
if count_A > 0 and count_B > 0:
  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):
S = input()
a = S.count('A')
b = S.count('B')

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

Solution (Python):
import sys

S=sys.stdin.readline()
m={}
for s in S:
    m[s] = True
if "A" in m and "B" in m:
    print("Yes")
else:
    print("No")

Solution (Python):

import sys
sys.setrecursionlimit(12345678)
import itertools
from collections import Counter
from collections import defaultdict
from collections import deque
import bisect
from heapq import heappush, heappop


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

if __name__ == '__main__':
    main()

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

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

Solution (Python):
S = input()
D = ['AAA','BBB']
if S in D:
  print('No')
else:
  print('Yes')

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

Solution (Python):
S = str(input())
if (S.count('A') == 0)or(S.count('B') == 0):
    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):
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 == 'AAA' or S == 'BBB':
  print('No')
else:
  print('Yes')

Solution (Python):
def check():
    s = input()
    value = s[0]
    if s.count(value) == 3:
        print('No')
    else:
        print('Yes')
check()

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

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

Solution (Python):
if input() in ["AAA", "BBB"]:
  print("No")
else:
  print("Yes")

Solution (Python):
import sys
sys.setrecursionlimit(10 ** 7)
read = sys.stdin.buffer.read 
inp = sys.stdin.buffer.readline
def inpS(): return inp().rstrip().decode()
readlines = sys.stdin.buffer.readlines 
MOD = 10**9+7

S = inpS()
ans = "No"
if S.count("A")!=3:
  if S.count("B")!=3:
    ans = "Yes"
print(ans)

Solution (Python):
import math
import numpy as np

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

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

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

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

Solution (Python):
s = input()
if len(set(s)) == 1:
    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 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()
ok = 'A' in S and 'B' in S
if ok:
    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):
printn = lambda x: print(x,end='')
inn = lambda : int(input())
inl   = lambda: list(map(int, input().split()))
inm   = lambda:      map(int, input().split())
ins = lambda : input().strip()
DBG = True 
BIG = 10**18
R = 10**9 + 7

def ddprint(x):
  if DBG:
    print(x)

s = ins()
hasa = (s[0]=='A') or (s[1]=='A') or (s[2]=='A')
hasb = (s[0]=='B') or (s[1]=='B') or (s[2]=='B')
if hasa and hasb:
    print('Yes')
else:
    print('No')

Solution (Python):
S = input()
topOfS = S[0]
isPass = False
for i in S:
  if topOfS != i:
    isPass = True
    break
if isPass == True:
  print("Yes")
else:
  print("No")

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

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

Solution (Python):
s = str(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):

from fractions import gcd
import math

from math import factorial as f

from math import ceil,floor,sqrt


import bisect
import re
import heapq


from copy import deepcopy
import itertools

from sys import exit

ii = lambda : int(input())
mi = lambda : map(int,input().split())
li = lambda : list(map(int,input().split()))

yes = "Yes"
no = "No"

def main():
    s = input()
    if s == 'AAA' or s == 'BBB':
        print(no)
    else:
        print(yes)






main()

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

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

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

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

Solution (Python):
s = [x for x in raw_input()]
print 'Yes' if len(set(s)) > 1 else 'No'

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

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

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

Solution (Python):
import sys
from itertools import combinations, permutations, product, combinations_with_replacement, accumulate
from heapq import heapify, heappop, heappush, heappushpop
from bisect import bisect_left, bisect_right
from collections import Counter, defaultdict, deque
from math import sqrt, log, floor, ceil, factorial, cos, sin, pi
from fractions import gcd
sys.setrecursionlimit(10**5)
input = sys.stdin.readline
INF = float('inf')
LINF = 2**63-1
NIL = -LINF
MOD = 10**9+7
MGN = 4
def II(): return int(input())
def IF(): return float(input())
def IS(): return str(input())
def ILCI(n: int): return [II() for _ in range(n)]
def ILCF(n: int): return [IF() for _ in range(n)]
def ILI(): return list(map(int, input().split()))
def ILLI(n: int): return [[int(j) for j in input().split()] for i in range(n)]
def ILF(): return list(map(float, input().split()))
def ILLF(n: int): return [[float(j) for j in input().split()] for i in range(n)]
def LTOS(lst: list, sep: str = ' '): return sep.join(map(str, lst))
def DEC(lst: list): return list(map(lambda x: x-1, lst))
def INC(lst: list): return list(map(lambda x: x+1, lst))


def main():
    S = IS()

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


if __name__ == '__main__':
    main()

Solution (Python):
import sys
from itertools import combinations, permutations, product, combinations_with_replacement, accumulate
from heapq import heapify, heappop, heappush, heappushpop
from bisect import bisect_left, bisect_right


sys.setrecursionlimit(10**5)
input = sys.stdin.readline
INF = float('inf')
LINF = 2**63-1
NIL = -LINF
MOD = 10**9+7
MGN = 4
def II(): return int(input())
def IF(): return float(input())
def IS(): return str(input())
def ILCI(n: int): return [II() for _ in range(n)]
def ILCF(n: int): return [IF() for _ in range(n)]
def ILI(): return list(map(int, input().split()))
def ILLI(n: int): return [[int(j) for j in input().split()] for i in range(n)]
def ILF(): return list(map(float, input().split()))
def ILLF(n: int): return [[float(j) for j in input().split()] for i in range(n)]
def LTOS(lst: list, sep: str = ' '): return sep.join(map(str, lst))
def DEC(lst: list): return list(map(lambda x: x-1, lst))
def INC(lst: list): return list(map(lambda x: x+1, lst))


def main():
    S = IS()

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


if __name__ == '__main__':
    main()

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

Solution (Python):
import sys
sys.setrecursionlimit(10**5)
input = sys.stdin.readline
INF = float('inf')
LINF = 2**63-1
NIL = -LINF
MOD = 10**9+7
MGN = 4
def II(): return int(input())
def IF(): return float(input())
def IS(): return str(input())
def ILCI(n: int): return [II() for _ in range(n)]
def ILCF(n: int): return [IF() for _ in range(n)]
def ILI(): return list(map(int, input().split()))
def ILLI(n: int): return [[int(j) for j in input().split()] for i in range(n)]
def ILF(): return list(map(float, input().split()))
def ILLF(n: int): return [[float(j) for j in input().split()] for i in range(n)]
def LTOS(lst: list, sep: str = ' '): return sep.join(map(str, lst))
def DEC(lst: list): return list(map(lambda x: x-1, lst))
def INC(lst: list): return list(map(lambda x: x+1, lst))


def main():
    S = IS()

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


if __name__ == '__main__':
    main()

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

Solution (Python):
S = input()

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

Solution (Python):
s = input()
for i in range(0,2):
  if s[i] != s[i+1]:
    print('Yes')
    break
else:
  print('No')

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

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

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

Solution (Python):
S = input()
A_cnt = S.count('A')
B_cnt = S.count('B')
if A_cnt == 0 or B_cnt == 0:
    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()
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):
s = input()
print("Yes" if not(s == "AAA" or s == "BBB") else "No")

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


arr = list(set(s))
if len(arr) == 2:
    print('Yes')
else:
    print('No')

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

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

answer = 'No'
count = N.count('A')
if count != 3 and count != 0:
    answer = 'Yes'

print(answer)

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

Solution (Python):
print('No') if input().count('A') in [0, 3] 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] and S[1] == S[2]:
    print('No')
else:
    print('Yes')

Solution (Python):
S=input()
c=0
for i in range(len(S)-1):
    if S[i]!=S[i+1]:
        c=c+1
        break 
if c==0:
    print("No")
else :
    print("Yes")

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

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

Solution (Python):
bus_services=input()

service=False
for i in range(len(bus_services)-1):
  if bus_services[i]!=bus_services[i+1]:
    service=True
if service==True:
  print('Yes')
else:
  print('No')

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

Solution (Python):

import sys

YES = "Yes"  
NO = "No"  


def solve(S: str):
   if len(set(list(S))) != 1:
   	print(YES)
   else:
   	print(NO)



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 s.count('B') == 3 or s.count('A') == 3:
  print("No")
else:
  print("Yes")

Solution (Python):
if __name__== '__main__':
  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()

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

S = str(input().strip('\n'))

if len(S) != 3 or S == 'AAA' or S == 'BBB':
    print('No')
    sys.exit()
else:
    for Count in range(1,4):
        if S[Count-1] =='A' or \
           S[Count-1] =='B':
            pass
        else:
            print('No')
            sys.exit()

print('Yes')

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

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

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

Solution (Python):

s=raw_input()
if s.count('A')==3 or s.count('B')==3:
 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):
S = set(input())

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

Solution (Python):
S = input()
print("YNeos"[S[0] == S[1] == S[2]::2])

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 == 'AAA' or s == 'BBB':
    print('No')

else: print('Yes')

Solution (Python):
class StationAndBus:
    def __init__(self):
        self.result = False
    
    def check_combination(self, str_list):
        if str_list.count(str_list[0]) == 0 or str_list.count(str_list[0])==3:
            self.result = False
        else:
            self.result = True
        return self.result

if __name__ == "__main__":
    S=list(input())
    sab = StationAndBus()
    result=sab.check_combination(S)
    if result:
        print("Yes")
    else:
        print("No")

Solution (Python):
stations = input()

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

Solution (Python):

from collections import defaultdict,deque
from heapq import heappush, heappop
from bisect import bisect_left, bisect_right
import sys, random, itertools, math
sys.setrecursionlimit(10**5)
input = sys.stdin.readline
sqrt = math.sqrt
def LI(): return list(map(int, input().split()))
def LF(): return list(map(float, input().split()))
def LI_(): return list(map(lambda x: int(x)-1, input().split()))
def II(): return int(input())
def IF(): return float(input())
def LS(): return list(map(list, input().split()))
def S(): return list(input().rstrip())
def IR(n): return [II() for _ in range(n)]
def LIR(n): return [LI() for _ in range(n)]
def FR(n): return [IF() for _ in range(n)]
def LFR(n): return [LI() for _ in range(n)]
def LIR_(n): return [LI_() for _ in range(n)]
def SR(n): return [S() for _ in range(n)]
def LSR(n): return [LS() for _ in range(n)]
mod = 1000000007
inf = float('INF')


def solve():
    s = S()
    print("Yes" if len(set(s)) == 2 else "No")
    return



if __name__ == '__main__':
    solve()

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

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

Solution (Python):
strs = input()
count_A = strs.count('A')
if count_A > 0 and count_A < 3:
  print('Yes')
else:
  print('No')

Solution (Python):

A=input()

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

Solution (Python):
strs = input()
count_A = strs.count('A')
if count_A > 0 and count_A < 3:
  print('Yes')
else:
  print('No')

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

countA = 0
countB = 0
for i in range(len(S)):
  if S[i] == "A":
    countA = countA + 1
  elif S[i] == "B":
    countB = countB + 1

if countA == 3 or countB == 3:
  print('No')
else:
  print('Yes')

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

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

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

Solution (Python):
S = input()
a = S.count(S[0])
if a ==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=list(input().strip())
x=s.count(s[0])
if x==0 or x==3:
    print('No')
else:
    print('Yes')

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

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

if a == b == c:
    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):
a=list(input())
if a[0]==a[1] and a[0]==a[2] and a[1]==a[2]:
  print('No')
else:
  print('Yes')

Solution (Python):
a_list = input()
a = a_list[0]
b = a_list[1]
c = a_list[2]
if a==b==c:
  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):
sta = input()
if 'A' in sta and 'B' in sta:
  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('Yes' if ('A' in s and 'B' in s) else 'No')

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

Solution (Python):
print("YNeos"[len(set(input()))==1::2])

Solution (Python):
import sys

def I(): return int(sys.stdin.readline())
def MI(): return map(int, sys.stdin.readline().split())
def LMI(): return list(map(int, sys.stdin.readline().split()))
MOD = 10 ** 9 + 7

S = input()
print('Yes' if S.count('A') > 0 and S.count('B') > 0 else 'No')

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

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

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

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

Solution (Python):
s = input()

a = s[0]
for i in range(1, 3) :
  if(s[i] != a) :
    print("Yes")
    exit()
print("No")

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

Solution (Python):
S = input()

ans = set(S)

print("Yes" if len(ans)>=2 else "No")

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

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

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

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

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

Solution (Python):
def solve(s):
    return "Yes" if len(set(s)) > 1 else "No"

s = input()
print(solve(s))

Solution (Python):


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

Solution (Python):
S = input()

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

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

Solution (Python):
s = input()
x = s[0]
flag = False
for i in range(len(s)):
  if s[i] != x:
    flag = True
    break
if flag == True:
  print("Yes")
else:
  print("No")

Solution (Python):

import sys
sys.setrecursionlimit(10**8)
INF = float("inf")


def yes():
    print("Yes")  


def no():
    print("No")  


def solve(S: str):
    if len(set(list(S))) == 1:
        no()
    else:
        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[0]==s[1]==s[2]:
    print("No")
else:
    print("Yes")

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

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

Solution (Python):
S = input()
if S.find("A") == -1 or S.find("B") == -1:
    print("No")
else:
    print("Yes")

Solution (Python):
S = input()
if S in ["AAA", "BBB"]:
    print("No")
else:
    print("Yes")

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

ss = set()

for c in s:
  ss.add(c)

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

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

Solution (Python):
a,b,c=input();print('YNeos'[a==b==c::2])

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):
s1=str(input())
if "A" in s1 and "B" in s1:
  print("Yes")
else:
  print("No")

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

Solution (Python):
S = list(input())
if S.count(S[0]) == 3:
  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())

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

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

Solution (Python):
N = input()
 

 
if N[0]==N[1]==N[2]:
    print('No')
    exit()
print('Yes')

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
MOD = 10 ** 9 + 7

S = input()

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

Solution (Python):
str = input()

ct = str.count('A')

if ct == 0 or ct == 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):

def main():
    S = set(input().rstrip())
    print("Yes" if len(S) == 2 else "No")


if __name__ == "__main__":
    main()

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

Solution (Python):
s = input()

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

Solution (Python):

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

Solution (Python):

a = str(input())

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

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