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.



Sample input:
ABA


Sample output:
Yes

Submission status: Accepted

Solution code:
s = input()
print('No' if s.count('A') > 2 or s.count('B') > 2 else 'Yes')

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

s = list(str(input()))

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

Solution code:
import itertools
import functools
import math
from collections import Counter
from itertools import combinations

S=input()

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

Submission status: Accepted

Solution code:
s = input()
if (s == "AAA") | (s == "BBB") :
    print("No")
else:
    print("Yes")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = str(input())
apple = []
for i in s:
    apple.append(i)
print("Yes" if len(set(apple)) == 2 else "No")

Submission status: Accepted

Solution code:
s = input()

s_set = set(s)

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

Submission status: Accepted

Solution code:
# A - Station and Bus
S = input()
if S[0]==S[1]==S[2]:
    print('No')
else:
    print('Yes')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = list(input())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s=input()

ans='Yes'

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

if a==b and b==c and a==c:
    ans='No'
print(ans)

Submission status: Accepted

Solution code:
s = input()
ans = "Yes"

if s[0]==s[1]==s[2]:
  ans = "No"

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
print('Yes') if len(set(input()))==2 else\
	print('No')

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

Solution code:
s = input()

if s.count("A") in [len(s), 0]: print("No")
else: print("Yes")

Submission status: Accepted

Solution code:
def main():
    stop = list(input())

    a, b = 0, 0
    for i in stop:
        if 'A' == i:
            a+=1
        else:
            b+=1
    if a > 0 and b > 0:
        print('Yes')
    else:
        print('No')
main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s=input()
print("YNeos"[s == len(s) * s[0]::2])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys 
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
S = readline().decode()
if 'A' in S and 'B' in S:
    print('Yes')
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
ans = 'No'
if "A" in s and "B" in s: ans = 'Yes'
print(ans)

Submission status: Accepted

Solution code:
S = str(input())

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

else:
    print("Yes")

Submission status: Accepted

Solution code:
# 160 A

s = input()
if ((s.count('A') == 2 and s.count('B') == 1) or (s.count('B') == 2 and s.count('A') == 1)):
    print("Yes")
else:
    print("No")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = set(input())

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

Submission status: Accepted

Solution code:

a=input()

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

Submission status: Accepted

Solution code:
#n, m, q = map(int, input().split())
#List = list(map(int, input().split()))
#req = [list(map(int, input().split())) for _ in range(q)]
#t = t[:-1]
#print(ans[j], end = "") 改行無しで出力
#[0]*n
s = input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = str(input())

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

Submission status: Accepted

Solution code:
S = input()

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

print("Yes")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s=len(set(i for i in input()))
print("YNeos"[s == 1::2])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=input()
if(S=='AAA' or S=='BBB'):

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=str(input())
result=0
if 'A' in S:
    if 'B' in S:
        result+=1
elif 'B' in S:
    if 'A' in S:
        result+=1
if result>=1:
    print('Yes')
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
## coding: UTF-8
S = input()

ans = 'No'

if(S[0] != S[1]):
    ans = 'Yes'
if(S[1] != S[2]):
    ans = 'Yes'
if(S[0] != S[2]):
    ans = 'Yes'
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()
S = sorted(S)
a = 'Yes'
if S[0] == S[-1]:
  a = 'No'
print(a)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = set(input())
if len(n) == 1:
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
S = list(input())

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

Submission status: Accepted

Solution code:
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')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()
a = 0
b = 0
for i in range(len(S)):
    if S[i] == 'A':
        a += 1
    elif S[i] == 'B':
        b += 1
if a == 0 or b == 0:
    print('No')
else:
    print('Yes')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = list(input())
s.sort()
if s[0] == s[2]:
    print('No')
else:
    print('Yes')

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
a = input()
if a == 'AAA' or a == 'BBB':
    print('No')
else:
    print('Yes')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = input()

if n.count("A") >= 1 and n.count("B") >= 1:
    print("Yes")
else:
    print("No")

Submission status: Accepted

Solution code:
s = set(input())
if s == {"A"} or s == {"B"}:
  print("No")

else:
  print("Yes")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def solve():
    S = input()
    print('YNeos'[S=='AAA' or S=='BBB'::2])

if __name__ == '__main__':
    solve()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

s = sys.stdin.readline()

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

Submission status: Accepted

Solution code:
S=list(input())

ans='No'

for i in range(2):
  if S[i+1]!=S[i]:
    ans='Yes'
    break

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

Solution code:
a = input()
print('NYoe s'['A' in a and 'B' in a::2])

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

Solution code:
if len(set(list(str(input())))) == 2:
    print('Yes')
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

Solution code:
s=input()
for i in s:
    for j in s:
        if i!=j:
            print('Yes')
            exit()
print('No')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

Solution code:
S = input()
ans = 'Yes'
if S == 'AAA' or S == 'BBB':
  ans = 'No'
print(ans)

Submission status: Accepted

Solution code:
S = list(input())

if len(set(S)) == 1:
  print('No')
else:
  print('Yes')
  
#ABA
#BBA
#BBB

Submission status: Accepted

Solution code:
S = input()

if 'A' in S and 'B' in S:
  print('Yes')
else:
  print('No')
  
#ABA
#BBA
#BBB

Submission status: Accepted

Solution code:
T=list(str(input()))
t=False
if not 'B' in T:
    t=True
if not 'A' in T:
    t=True
if not  t:
    print('Yes')
else:
    print('No')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import numpy as np
import scipy.sparse as sps
import scipy.misc as spm
import collections as col
import functools as func
import itertools as ite
import fractions as frac
import math as ma
import cmath as cma
import copy as cp
import sys
def sinput(): return sys.stdin.readline().strip()
def iinput(): return int(sinput())
def imap(): return map(int, sinput().split())
def fmap(): return map(float, sinput().split())
def iarr(n=0):
    if n: return [0 for _ in range(n)]
    else: return list(imap())
def farr(): return list(fmap())
def sarr(n=0):
    if n: return ["" for _ in range(n)]
    else: return sinput().split()
def barr(n): return [False for _ in range(n)]
sys.setrecursionlimit(10**7)
MOD = 10**9 + 7; EPS = sys.float_info.epsilon
PI = np.pi; EXP = np.e; INF = np.inf

s = sinput()
flag = all(c == "A" for c in s) or all(c == "B" for c in s)
ans = "No" if flag else "Yes"
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=input()
Aflug=False
Bflug=False

for i in range(3):
    if S[i]=="A":
        Aflug=True
    else:
        Bflug=True

if Aflug==True and Bflug==True:
    print("Yes")
else:
    print("No")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

Solution code:
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')

Submission status: Accepted

Solution code:
import sys

input = lambda: sys.stdin.readline().rstrip()


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


if __name__ == '__main__':
    solve()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()
# バリエーションが1種類全文重複してるならNO
if len(set(S)) == 1:
    print('No')
else:
    print('Yes')

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s=input();print('YNeos'[s=='AAA' or s=='BBB'::2])

Submission status: Accepted

Solution code:
print(["Yes","No"][len(set(list(input()))) == 1])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
input = lambda: sys.stdin.readline().rstrip()

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

if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S= input()

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

Submission status: Accepted

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

main()

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

Solution code:
s = input()
dic = []

for t in s:
    if t not in dic:
        dic += t

ans = "No"
if len(dic) > 1:
    ans = "Yes"

print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

Solution code:
x = list(input())
if "A" in x and "B" in x:
  print("Yes")
else:
  print("No")

Submission status: Accepted

Solution code:
S = input()
if "A" not in S or "B" not in S:
    print("No")
else:
    print("Yes")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

Solution code:
a=input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = input()
n = []
for i in s:
  n.append(i)
  
if 'A' not in n:
  print('No')
elif 'B' not in n:
  print('No')
elif 'A' and 'B' in n:
  print('Yes')

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=list(input())
if S[0]==S[2] and S[0]==S[1]:
  print("No")

else:
  print("Yes")

Submission status: Accepted

Solution code:
def resolve():
    s = input()

    flag = False
    head = s[0]
    for i in range(1, len(s)):
        if head != s[i]:
            flag = True

    print('Yes' if flag else 'No')
resolve()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

Solution code:
stations = input()

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
s = str(input())

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

Submission status: Accepted

Solution code:
s = input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
x = input()
flg = 0
for i in x:
  for j in x:
    if i != j:
      flg = 1
if flg == 1:
  print('Yes')
else:
  print('No')

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
x = list(input())
if x.count(x[0]) == 3:
    print("No")
else:
    print("Yes")

Submission status: Accepted

Solution code:
s = input()
ans = "No"
pre = s[0]
for i in range(1,3):
    if(s[i] != pre):
        ans = "Yes"
        break
    pre = s[i]
print(ans)

Submission status: Accepted

Solution code:
#A
s = input()
s1, s2 , s3 = s[0], s[1], s[2]
if s1 != s2 or s1 != s3 or s2 != s3:
    print("Yes")
else:
    print("No")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

def ep(*params):
    print(*params,file=sys.stderr)

#() = list(map(int,input().split()))
S = input().rstrip()
if S == 'AAA' or S == 'BBB':
    print("No")
else:
    print("Yes")

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S=input()

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-


def get_input() -> str:
    """
    標準入力の取得.

    Returns:\n
        str: 標準入力
    """
    S = input()

    return S


def main(S: str) -> None:
    """
    求解処理.

    Args:
        S (str): 管理状況
    """
    result = str()
    if S == "AAA" or S == "BBB":
        result = "No"
    else:
        result = "Yes"

    # 結果出力
    print(result)


if __name__ == "__main__":
    S = get_input()
    main(S)

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
# 標準入力の取得
S = input()

# 求解処理
result = str()
if S == "AAA" or S == "BBB":
    result = "No"
else:
    result = "Yes"

# 結果出力
print(result)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a = input()

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

Submission status: Accepted

Solution code:
# coding: utf-8
str = input()
if str[0] == "A" and str[1] == "A" and str[2] == "A":
    print("No")
elif str[0] == "B" and str[1] == "B" and str[2] == "B":
    print("No")
else:
    print("Yes")

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import bisect,collections,copy,heapq,itertools,math,numpy,string
import sys
sys.setrecursionlimit(10**7)

def _S(): return sys.stdin.readline().rstrip()
def I(): return int(sys.stdin.readline().rstrip())
def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))
def LS(): return list(sys.stdin.readline().rstrip().split())

def main():
    S = _S()
    print("Yes" if not(S=="AAA" or S=="BBB") else "No")

main()

Submission status: Accepted

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

Submission status: Accepted

Solution code:
S = set(i for i in input())
print('Yes' if len(S) == 2 else 'No')

Submission status: Accepted

Solution code:
S = input()

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

Submission status: Accepted

Solution code:
S=input()

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

Submission status: Accepted

Solution code:
S = list(input())
a = S.count("A")
b = S.count("B")

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
print(["No","Yes"][len(set(input()))-1])

Submission status: Accepted

Solution code:
n=input()
cnta=0
cntb=0
for e in n:
  if e=="A":
    cnta+=1
  elif e=="B":
    cntb+=1
if cnta==0 or cntb==0:
  print('No')
else:
  print('Yes')

Submission status: Accepted

Solution code:
a="No"
l = list(input())
for i in range(len(l)):
	if i!=0:
		if l[i]!=l[i-1]: a="Yes"
print(a)