Problem:


Score : 100 points

Problem Statement

AtCoder Inc. holds a contest every Saturday.

There are two types of contests called ABC and ARC, and just one of them is held at a time.

The company holds these two types of contests alternately: an ARC follows an ABC and vice versa.

Given a string S representing the type of the contest held last week, print the string representing the type of the contest held this week.

Constraints

S is ABC or ARC.

Input

Input is given from Standard Input in the following format:

S

Output

Print the string representing the type of the contest held this week.

Sample Input 1

ABC

Sample Output 1

ARC

They held an ABC last week, so they will hold an ARC this week.



Sample input:
ABC


Sample output:
ARC

Submission status: Runtime Error

Solution code:
S = input()
if S == 'ARC:
  print("ABC")
else:print('ARC')

Submission status: Runtime Error

Solution code:
if S == ABC:
  print(ARC)
 
else:print(ABC)

Submission status: Runtime Error

Solution code:
s = input()

if s[1] == 'B':
  s[1] = 'R'
else: 
  s[1] = 'B'
  
print(s)

Submission status: Runtime Error

Solution code:

if S == "ABC":
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
S = input()
if S == "ABC":
  print "ARC"
else:
  print "ABC"

Submission status: Runtime Error

Solution code:
if S == "ABC":
  return "ARC"
else:
  return "ABC"

Submission status: Runtime Error

Solution code:
 s = ''
if s == 'ABC':
  print('ARC')
else :
  print('ABC')

Submission status: Runtime Error

Solution code:
return 'ARC' if S == 'ABC' else 'ABC'

Submission status: Runtime Error

Solution code:
x=int(input())
for i in range(-1000,1000):
  for j in range(-1000,1000):
    if i**5 ==x+j**5:
      print(i,j)
      exit()

Submission status: Runtime Error

Solution code:
t=input()
if(t=="ABC"){
	print("ARC")}
else{
	print("ABC")}

Submission status: Runtime Error

Solution code:
n = int(input())
a = list(map(int, input().split()))

nn = n + max(a)
ml = [0] * nn
pl = [0] * nn

out = 0

for i in range(0, n):
    pl[i+a[i]] += 1
    if(i-a[i]>=0):
        ml[i-a[i]] += 1

for i in range(0, n):
    out += pl[i] * ml[i]

print(out)

Submission status: Runtime Error

Solution code:
n = int(input())
a = list(map(int, input().split()))

out = 0

for i in range(n):
    w = i-a[i]
    for j in range(i):
        if(w == a[j] + j):
            out += 1
print(out)

Submission status: Runtime Error

Solution code:
N, M = map(int, input().split(" "))
height = list(map(int, input().split(" ")))
flag = [1 for i in height]
for i in range(M):
  a, b = map(int, input().split(" "))
  if height[a - 1] > height[b - 1]:
    flag[b - 1] = 0
  elif height[b - 1] > height[a - 1]:
    flag[a - 1] = 0
  else:
    flag[a - 1] = 0
    flag[b - 1] = 0
print(sum(flag))

Submission status: Runtime Error

Solution code:
N, K = map(int, input().split(" "))
flag = [1 for i in range(N)]
for i in range(K):
  input()
  for j in map(int,input().split(" ")):
    flag[j-1] = 0
sum(flag)

Submission status: Runtime Error

Solution code:
if imput() = "ABC":
  print("ADC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
N,M = map(int,input().split())
H = list(map(int,input().split()))
P = [0] * N
for i in range(M) :
    q = list(map(int,input().split()))
    p = P[q[0]-1]
    h = H[q[1]-1]
    if p < h :
        P[q[0]-1] = H[q[1]-1]
    if p > h :
        P[q[1]-1] = H[q[0]-1]

R = 0
for i in range(N) :
    if H[i] > P[i] :
        R += 1
print(R)

Submission status: Runtime Error

Solution code:
list = ['ABC','ARC']
if s == 'ABC':
	print(list[1])
else:
  print(list[0])

Submission status: Runtime Error

Solution code:
d = {'B':'R', 'R':'B'}
s = str(input())
s[1] = d[s[1]]
print(s)

Submission status: Runtime Error

Solution code:
str = input()
if str = 'ABC':
  print(str.replace('B','R'))
else:
  print(str.replace('B','R'))

Submission status: Runtime Error

Solution code:
str = input()
if str = 'ARC':
  print(str.replace('B','R'))
else:
  print(str.replace('B','R'))

Submission status: Runtime Error

Solution code:
s = inport()
print("ABC" if s=="ARC" else "ARC")

Submission status: Runtime Error

Solution code:
inpo=inport()
for i in inpo:
  if i=="B":
    print("R",end="")
  elif i=="R":
    print("B",end="")
  else:
    print(i,end="")

Submission status: Runtime Error

Solution code:
inpo=inport()
for i in inpo:
  if i=="B":
    print("R",end="")
  elif i=="R":
    print("B",end="")
  else:
    print(i)

Submission status: Runtime Error

Solution code:
inpo=inport()
for i in inpo:
  if i=="B":
    print("R")
  elif i=="R":
    print("B")
  else:
    print(i)

Submission status: Runtime Error

Solution code:
s = input()
if s == 'ABC:
	print('ARC')
else:
	print('ABC')

Submission status: Runtime Error

Solution code:
s=input()
if s[1]=='B':
  s[1]='R'
else:
  s[1]='B'
print(s)

Submission status: Runtime Error

Solution code:
s=input()
if s[1]=='B':
  s[1]='R'
else:
  s[1]='B';
print(s)

Submission status: Runtime Error

Solution code:
s=input()
if s==ABC:
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
s=input()
if s="ARC":
  print("ABC")
elif s="ABC":
  print("ARC")

Submission status: Runtime Error

Solution code:
S=intput()

if S=="ABC":
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
n,m = map(int,input().split())
height = list(map(int,input().split()))
lst = [0]*n
for j in range(m):
    x,y = map(int,input().split())
    if height[x-1] >= height[y-1]:
      lst[y-1] = 1
    if height[x-1] <= height[y-1]:
      lst[x-1] = 1
print(lst.count(0))

Submission status: Runtime Error

Solution code:
n,m = map(int,input().split())
height = list(map(int,input().split()))
lst = [0]*n
for j in range(m):
    x,y = map(int,input().split())
if height[x-1] >= height[y-1]:
    lst[y-1] = 1
if height[x-1] <= height[y-1]:
    lst[x-1] = 1
print(lst.count(0))

Submission status: Runtime Error

Solution code:
S = input()
if S == 'ABC' :
    Next = 'ARC'
else :
    Next = 'ABC'
print Next

Submission status: Runtime Error

Solution code:
import sys
import math

n, m = map(int, input().split())
h = list(map(int, input().split()))
ma = [0] * n
for i in range(m):
    a, b = map(int, input().split())
    ma[a - 1] = max(h[a - 1],max(ma[a-1],h[b - 1]))
    ma[b - 1] = max(h[b - 1],max(ma[b-1] ,h[a - 1]))
cnt = 0
for i in range(n):
    if h[i] >= ma[i]:
        cnt += 1
print(cnt)

Submission status: Runtime Error

Solution code:
if ABC in input():
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
S = str(input())

if S = 'ABC':
  print('ARC')
  
else:
  print('ABC')

Submission status: Runtime Error

Solution code:
k = ["ABC":"ARC","ARC":"ABC"]
print(k[input()])

Submission status: Runtime Error

Solution code:
N, M = (int(i) for i in input().split())
H = list(map(int,input().split()))
ans = [1]*N
for m in range(M):
  a, b = (int(i) for i in input().split())
  if H[a-1] <= H[b-1]:
    ans[a-1] = 0
  elif H[a-1] > H[b-1]:
    ans[b-1] = 0
print(ans.count(1))

Submission status: Runtime Error

Solution code:
N, K = (int(i) for i in input().split())
H = list(map(int,input().split()))
ans = [1]*N
for m in range(M):
  a, b = (int(i) for i in input().split())
  if H[a-1] <= H[b-1]:
    ans[a-1] = 0
  elif H[a-1] > H[b-1]:
    ans[b-1] = 0
print(ans.count(1))

Submission status: Runtime Error

Solution code:
if S == 'ABC':
	print('ARC')
else:
  print('ABC')

Submission status: Runtime Error

Solution code:
n, k = map(int, input().split())
n_list = list(range(1, n+1))
for _ in range(k):
    d = int(input())
    for _ in range(d):
        a = int(input)
        if a in n_list:
            n_list.remove(a)
print(len(n_list))

Submission status: Runtime Error

Solution code:
var str = readLine()!

if str=="ABC"{
  print("ARC")
}else{
  print("ABC")
}

Submission status: Runtime Error

Solution code:
if S=='ABC':
  print('ARC')
else:
  print('ABC')

Submission status: Runtime Error

Solution code:
if S="ABC":
  print("ARC")
 else:
  print("ABC")

Submission status: Runtime Error

Solution code:
ABC

Submission status: Runtime Error

Solution code:
comp = input()
if comp=="ABC":
  print("ARC")
else:
  print("ABC)

Submission status: Runtime Error

Solution code:
S = input()

if S == "ABC":
  print(ARC)
else:
  print(ABC)

Submission status: Runtime Error

Solution code:
s = raw_input()
print({"ARC":"ABC", "ABC":"ARC"}[s])

Submission status: Runtime Error

Solution code:
N = int(input())
A = list(map(int,input().split()))
l=0

for i in range(N):
    if A[i]>2*100000:
        A.remove(A[i])
N=len(A)
for i in range(N):
        for k in range(i+1 , N):
            if A[i]+A[k]==k-i or A[i]+A[k]==i-k:
                l+=1
print(l)

Submission status: Runtime Error

Solution code:
n = int(input())
 
a = [i**5 for i in range(120)]
for i in range(119):
    for j in range(i+1,119):
        if a[j]-a[i] == n:
            print(j,i)
            break
        if a[j]+a[i] == n:
            print(j,-i)
            break
    else: continue
    break

Submission status: Runtime Error

Solution code:
a = int(input())
if a == 'ABC':
    print('ARC')
else:
    print('ABC')

Submission status: Runtime Error

Solution code:
n, k = map(int, input().split())
a = set()

for _ in range(k):
  d = int(input())
  while m <= d:
    l = int(input())
    a.append(l)
    m += 1

print(n - len(a))

Submission status: Runtime Error

Solution code:
if(input().rstrip() == 'ABC':
   print('ARC')
else:
   print('ABC')

Submission status: Runtime Error

Solution code:
N = input()
if N = "ABC" :
  print("ARC")
elif N = "ARC" :
  print("ABC")

Submission status: Runtime Error

Solution code:
str = input()

if(str == 'ARC'){
  print('ABC')
}else{
  print('ARC')
}

Submission status: Runtime Error

Solution code:
if S = "ARC":
  print("ABC")
else:
  prnit("ABC")

Submission status: Runtime Error

Solution code:
S = input()
if S = "ABC":
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
if S = "ABC"
print("ARC")
else
print("ABC")

Submission status: Runtime Error

Solution code:
N,K=map(int,input().split())
hoge={}
for j in range(K):
    input()
    [hoge.update({int(j):1}) for j in input().split()]
print(sum([not j in hoge for j in range(N)]))

Submission status: Runtime Error

Solution code:
if __name__ = "__main__":
  S = input() # sを取得し、strに値を入れる
  if S == "ABC":
    print("ARC")
  elif S == "ARC":
    print("ABC")

Submission status: Runtime Error

Solution code:
if __name__ = "__main__":
  S = input() # sを取得し、strに値を入れる
  if S == "ABC":
    print "ARC"
  elif S == "ARC":
    print "ABC"

Submission status: Runtime Error

Solution code:
if

Submission status: Runtime Error

Solution code:
mycode

Submission status: Runtime Error

Solution code:
string x=input()
if x=="ABC":
    print("ARC")
else:
    print("ABC")

Submission status: Runtime Error

Solution code:
x=string(input())
if x=="ABC":
    print("ARC")
else:
    print("ABC")

Submission status: Runtime Error

Solution code:
a = input()
if(a == "ARC"):
  print("ABC")
elsif(a == "ABC"):
  print("ARC")

Submission status: Runtime Error

Solution code:
char = input()
if(char == "ARC"):
  print("ABC")
elsif(char == "ABC"):
  print("ARC")

Submission status: Runtime Error

Solution code:
s = input()
if s == "ABC":
  print("ARC")
else:
  print("ABC"

Submission status: Runtime Error

Solution code:
S=input()
if S==ABC:
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
s=input()
if s==ABC:
  print("ARC")
if s==ARC:
  print("ABC")

Submission status: Runtime Error

Solution code:
S = input()

if S == ABC :
  print("ARC")
else :
  print("ABC")

Submission status: Runtime Error

Solution code:
S = input()

if S == ABC :
  print(ARC)
else :
  print(ABC)

Submission status: Runtime Error

Solution code:
s = input()

if s == "ABC":
  ans = "ARC"
else:
  ans = "ABC"
  
 print(ans)

Submission status: Runtime Error

Solution code:
s = input()

if s == "ABC":
  ans = "ARC"
 else:
  ans = "ABC"
  
 print(ans)

Submission status: Runtime Error

Solution code:
s = input()

if s == "ABC":
    return "ARC"
else:
    return "ABC"

Submission status: Runtime Error

Solution code:
import numpy as np
N, M = list(map(int, input().split()))
H = list(map(int, input().split()))
G = N
lists = np.zeros(N)
for i in range(M):
    A, B = list(map(int, input().split()))
    if H[A-1] < H[B-1]:
        lists[A-1] = 1
    else:
        lists[B-1] = 1
for i in range(N):
    if lists[i] == 1:
        G -= 1
print(lists)
print(G)

Submission status: Runtime Error

Solution code:
S = ABC
B = R
print('S1')

Submission status: Runtime Error

Solution code:
x = int(input())
eps = 1e-9
a = 1
while a**5 <= x:
    diff = a**5-x
    if diff < 0:
        diff = abs(diff)
        sign = True
    else:
        sign = False
    if abs(diff**0.2 - round(diff**0.2)) < eps:
        b = round(round(diff**0.2))
        if sign:
            b = -b
        break
    a += 1
print(a,int(b))

Submission status: Runtime Error

Solution code:
    x = input()
    def f(x):
      if x == "ABC":
        print("ARC")
      elif x == "ARC":
        print("ABC")
      else:
        print("invalid input")
     
    print(f(x))

Submission status: Runtime Error

Solution code:
x = input()
def f(x):
  if x == ABC:
    print("ARC")
  elif x == ARC:
    print("ABC")
  else:
    print("invalid input")

print(f(x))

Submission status: Runtime Error

Solution code:
x = input()
if x == ARC:
  print("ABC")
elif x == ABC:
  print("ARC")
else:
  print("invalid input")

Submission status: Runtime Error

Solution code:
N,K = list(map(int,input().split()))

snk_sweets = []

for i in range(K):
    sweets = int(input())
    snk_sweets = snk_sweets + input().split()

len_snk = len(snk_sweets)
print(N - len_snk)

Submission status: Runtime Error

Solution code:
a = raw_input()

if a == "ABC":
  print("ARC")
elif a == "ARC":
  print("ABC")

Submission status: Runtime Error

Solution code:
a = raw_input()

if a == "ABC":
  print(ARC)
 elif a == "ARC":
  print(ABC)

Submission status: Runtime Error

Solution code:

S = input('=')

if S == 'ABC':
    print('ARC')
else S == 'ARC':
    print('ABC')

Submission status: Runtime Error

Solution code:
S = ''

if S == 'ABC':
    print('ARC')
else S == 'ARC':
    print('ABC')

Submission status: Runtime Error

Solution code:
if S == 'ABC':
    print('ARC')
else S == 'ARC':
    print('ABC')

Submission status: Runtime Error

Solution code:
s = input()
if s="ABC":
    print("ARC")
else:
    print("ABC")

Submission status: Runtime Error

Solution code:

if S == 'ABC':
    print('ARC')
elif S== 'ARC':
    print('ABC')
else:
    print(' ')

Submission status: Runtime Error

Solution code:

var S = input('先週開催されたコンテストは？')

if S == 'ABC':
  print('ARC')
elif S == 'ARC':
  print('ABC')

Submission status: Runtime Error

Solution code:
input()
ans = 'ABC' if s == 'ARC' else 'ARC'
print(ans)

Submission status: Runtime Error

Solution code:
x = input()
if x == ABC:
    print('ARC')
else:
    print('ABC')

Submission status: Runtime Error

Solution code:
S = input()
if S ='ABC':
 print('ARC')
else:
 print('ABC')

Submission status: Runtime Error

Solution code:
S = input()
if S='ABC':
  print('ARC')
else :
  print('ABC')

Submission status: Runtime Error

Solution code:
s = input()
if s == "ABC":
  print("ARC")
  else if:
    print("ABC")

Submission status: Runtime Error

Solution code:
S=input()
if (S==ABC):
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
N, M = map(int, input().split())
O = list(map(int, input().split()))
B = [[0 for i in range(N)] for j in range (N)]
 
for j in range(M):
  o_1, o_2 = map(int, input().split())
  B[o_1-1].append(o_2-1)
  B[o_2-1].append(o_1-1)
  
ans = 0
for k in range(N):
  flag =1
  for l in B[k]:
    if O[k] <= O[l]:
      flag = 0
      break
    else:
      continue
  if  flag ==1:
    ans += 1
print(ans)

Submission status: Runtime Error

Solution code:
N, M = map(int, input().split())
O =  [0]*N
B = [[0 for i in range(N)] for j in range (N)]
a = list(map(int, input().split()))
for i in range(N):
  O[i] = a[i]
 
for j in range(M):
  o_1, o_2 = map(int, input().split())
  B[o_1-1][o_2-1] = 1
  B[o_2-1][o_1-1] = 1
 
ans = 0
for k in range(N):
  flag =1
  for l in range(N):
    if B[k][l] == 1 and O[k] <= O[l]:
      flag = 0
  if  flag ==1:
    ans += 1
print(ans)

Submission status: Runtime Error

Solution code:
N,M=map(int, input().split())
H=list(map(int, input().split()))
flag=[1]*N
for i in range(M):
    A,B=map(int, input().split())
    if H[A-1]>H[B-1]:
        flag[B-1]=0 
    elif H[A-1]<H[B-1]:
        flag[A-1]=0
    else:
        flag[A-1]=0
        flag[B-1]=0
print(sum(flag))

Submission status: Runtime Error

Solution code:
input1 = input().rstrip().split(" ")
h = input().rstrip().split(" ")
yoi = [1 for i in range(int(input1[0]))]
root =  [input().rstrip().split(" ") for i in range(int(input1[1]))]
print(int(root[0][1]))
for i in range(int(input1[1])):
    a=int(root[i][0])-1
    b=int(root[i][1])-1
    if h[a]> h[b]:
        yoi[b] = 0
    elif h[a] < h[b]:
        yoi[a] = 0
    else:
        yoi[a] = 0
        yoi[b] = 0
print (sum(yoi))

Submission status: Runtime Error

Solution code:
if input() == ABC:
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
if input() == ABC:print("ARC") else:print("ABC")

Submission status: Runtime Error

Solution code:
S = "ABC"

if (S == "ABC")
	print("ARC")
else
	print("ABC")

Submission status: Runtime Error

Solution code:
N=int(input())
def contest(N):
  if N=="ABC":
    return ARC
  else:
    return ABC
contest(N)

Submission status: Runtime Error

Solution code:
n,k = map(int,input().split())
list=[]
for i in range(k):
    d = int(input())
    sunuke = map(int,input().split())
    for j in sunuke:
        if j not in list:
            list.append(j)
print(str(n - len(list)))

Submission status: Runtime Error

Solution code:
n,k = map(int,input().split())
list=[]
for i in range(k):
    d = int(input())
    sunuke = input().split()
    for j in range(d):
        if int(sunuke[j]) not in list:
            list.append(int(sunuke[j]))
print(str(n - len(list)))

Submission status: Runtime Error

Solution code:
s=str(input())
if s=="ABC":
  print(“ARC”)
else:
  print(“ABC”)

Submission status: Runtime Error

Solution code:
S = input()
  
print("ARC" if S == "ABC else "ABC")

Submission status: Runtime Error

Solution code:
s = str(input())
if s == ABC:
    ans = ARC
else :
    ans == ABC
print(ans)

Submission status: Runtime Error

Solution code:
S = str(input())
if S == 'ABC':
  return 'ARC'
else:
  return 'ABC'

Submission status: Runtime Error

Solution code:
if S == 'ABC':
  return 'ARC'
else:
  return 'ABC'

Submission status: Runtime Error

Solution code:
if S = 'ABC':
  return 'ARC'
else:
  return 'ABC'

Submission status: Runtime Error

Solution code:
contest = input()

if contest = "ABC":
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
S = input()
assert S == ("ABC" or "ARC"), "Sは、ABCまたはARCです"
if S == "ABC":
    print("ARC")
else:
    print("ABC")

Submission status: Runtime Error

Solution code:
#S = input()

if(S == "ABC"):
	print("ARC")
elif(S == "ARC"):
	print("ABC")

Submission status: Runtime Error

Solution code:
S = input()

if(S == ABC):
	print("ARC")
elif(S == ARC):
	print("ABC")

Submission status: Runtime Error

Solution code:
if(S == ABC):
	print("ARC")
elif(S == ARC):
	print("ABC")

Submission status: Runtime Error

Solution code:
s = input()
s[1] = "R"
print(s)

Submission status: Runtime Error

Solution code:
if(S == ABC){
	print("ARC")
}
else if(S == ARC){
	print("ABC")
}

Submission status: Runtime Error

Solution code:
if(S == ABC){
	print("ARC")
}
else if(S == ARC){
	print("ABC");
}

Submission status: Runtime Error

Solution code:
#include <iostream>

using namespace std;

int main(){

string str
cin>>str
if str == "ABC"{
cout<<"ARC"<<endl;
} else if str == "ARC"{
cout<<"ABC"<<endl;
}
retrun 0;
}

Submission status: Runtime Error

Solution code:
str = String(input())
if str == "ARC":
	print("ABC")
else:
	print("ARC")

Submission status: Runtime Error

Solution code:
N,A,B,C = map(int,input().split())
s = []
for i in range(int(N)):
    s.append(input())

r =''
select =''
result = []
#print(' ',A,B,C)

for i in range(N):
    if (A== 0 and B ==0) :
        if s[i] == 'AB': 
            r = 'No'
            break
    if  (C== 0 and B ==0):
        if s[i] == 'BC':
            r = 'No'
            break
    if  (A== 0 and C ==0):
        if s[i] == 'AC': 
            r = 'No'
            break

    if s[i] == 'AB':
        if A*B == 1:
            if i < N:
                if s[i] == 'BC':
                    A += -1
                    B += +1
                    select ='B'
                if s[i] == 'AC':
                    A += +1
                    B += -1
                    select ='A'
            else:
                A += +1
                B += -1
                select ='A'

        else :
            if A <= B:    
                select ='A'
                A += +1
                B += -1
            else:
                select ='B'
                A += -1
                B += +1

                
    if s[i] == 'BC':
        if B*C == 1:
            if i < N:
                if s[i] == 'AB':
                    select ='B'
                    C += -1
                    B += +1
                if s[i] == 'AC':
                    select ='C'
                    C += +1
                    B += -1
            else:
                select ='B'
                B += +1
                C += -1

        else :
            if B <= C:    
                select ='B'
                B += +1
                C += -1
            else:
                select ='C'
                B += -1
                C += +1
            
    if s[i] == 'AC':
        if A*C == 1:
            if i < N:
                if s[i] == 'BC':
                    A += -1
                    C += +1
                    select ='C'
                if s[i] == 'AB':
                    A += +1
                    C += -1
                    select ='A'
            else:
                A += +1
                C += -1
                select ='A'

        else :
            if A <= C:    
                select ='C'
                A += -1
                C += +1
            else:
                select ='A'
                A += +1
                C += -1
    result.append(select)

if r == 'No':
    print('No')
else: 
    print('Yes')
    for i in range(N):
        print(result[i])

Submission status: Runtime Error

Solution code:
for i in range(int(N)):
    s.append(input())

r =''
select =''
result = []
#print(' ',A,B,C)

for i in range(N):
    if (A== 0 and B ==0) :
        if s[i] == 'AB': 
            r = 'No'
            break
    if  (C== 0 and B ==0):
        if s[i] == 'BC':
            r = 'No'
            break
    if  (A== 0 and C ==0):
        if s[i] == 'AC': 
            r = 'No'
            break

    if s[i] == 'AB':
        if A*B == 1:
            if i < N:
                if s[i] == 'BC':
                    A += -1
                    B += +1
                    select ='B'
                if s[i] == 'AC':
                    A += +1
                    B += -1
                    select ='A'
            else:
                A += +1
                B += -1
                select ='A'

        else :
            if A <= B:    
                select ='A'
                A += +1
                B += -1
            else:
                select ='B'
                A += -1
                B += +1

                
    if s[i] == 'BC':
        if B*C == 1:
            if i < N:
                if s[i] == 'AB':
                    select ='B'
                    C += -1
                    B += +1
                if s[i] == 'AC':
                    select ='C'
                    C += +1
                    B += -1
            else:
                select ='B'
                B += +1
                C += -1

        else :
            if B <= C:    
                select ='B'
                B += +1
                C += -1
            else:
                select ='C'
                B += -1
                C += +1
            
    if s[i] == 'AC':
        if A*C == 1:
            if i < N:
                if s[i] == 'BC':
                    A += -1
                    C += +1
                    select ='C'
                if s[i] == 'AB':
                    A += +1
                    C += -1
                    select ='A'
            else:
                A += +1
                C += -1
                select ='A'

        else :
            if A <= C:    
                select ='C'
                A += -1
                C += +1
            else:
                select ='A'
                A += +1
                C += -1
    result.append(select)

if r == 'No':
    print('No')
else: 
    print('Yes')
    for i in range(N):
        print(result[i])

Submission status: Runtime Error

Solution code:
S == 'ABC'

if S == 'ABC':
 print('ARC')
else:
 print('ABC')

Submission status: Runtime Error

Solution code:

if S == "ABC":
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
if S == 'ABC':
 print('ARC')
else:
 print('ABC')

Submission status: Runtime Error

Solution code:
S = 'ABC'
if S = 'ABC':
print('ARC')
else:
print('ABC')

Submission status: Runtime Error

Solution code:
S == 'ABC'

if S == 'ABC' :
 print('ARC')
else :
 print('ABC')

Submission status: Runtime Error

Solution code:
S = ABC

if S = ABC:
 print('ARC')
else:
 print('ABC')

Submission status: Runtime Error

Solution code:
S = ABC

if S == ABC:
 print('ARC')
else:
 print('ABC')

Submission status: Runtime Error

Solution code:
S = ABC
if S = ABC:
 print("ARC")
else:
 print("ABC")

Submission status: Runtime Error

Solution code:
if S = 'ABC':
 print('ARC')
else:
 print('ABC')

Submission status: Runtime Error

Solution code:
if S = ABC:
 print('ARC')
elf:
 print('ABC')

Submission status: Runtime Error

Solution code:
if S = ABC:
 print('ARC')
else:
 print('ABC')

Submission status: Runtime Error

Solution code:
S == input()
if S = "ABC":
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
x=input()
if x=ABC:
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
s= map.input()
if(s == "ABC"):
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
s = input().split()
if(s = 'ABC'):
  print("ARC")
else:
  print("ABC")

Submission status: Runtime Error

Solution code:
S = input()

if S = 'ARC':
	print('ABC')
else
	ptint('ARC')

Submission status: Runtime Error

Solution code:
S = input()
if S = 'ABC':
    print('ARC')
else:
    print('ABC')

Submission status: Runtime Error

Solution code:
def main():
    a = 'ABC'
    r = 'ARC'
    s = input()
    if s == a:
        print(r)
    else:
        print(a)
    
    print(ans)

if __name__ == '__main__':
    main()

Submission status: Runtime Error

Solution code:
if S=="ABC":
    print("ARC")
else:
    print("ABC")

Submission status: Runtime Error

Solution code:
s = input()
if(s[1] == "R"):
  print("ABC")
 else:
  print("ARC")

Submission status: Runtime Error

Solution code:
s = input()
if s == "ARC":
  print("ABC")
 else:
  print("ARC")

Submission status: Runtime Error

Solution code:
s=input()
 if s=='ABC':
    print("ARC")
 else:
    print("ABC")

Submission status: Runtime Error

Solution code:
def resolve():
	x = int(input())
	for i in range(1000):
		for j in range(-1000, 1000):
			if i**5 - j**5 == x:
				print(i, j)
				return

resolve()

Submission status: Runtime Error

Solution code:
n,m=map(int,input().split())
h=list(map(int,input().split()))
ans=[1]*n
for _ in range(m):
  a,b=map(int,input().split())
  if ans[a-1]:
    if h[a-1]<=h[b-1]:
      ans[a-1]=0
  if ans[b-1]:
    if h[b-1]<=h[a-1]:
      ans[b-1]=0
print(ans.count(1))

Submission status: Runtime Error

Solution code:
last = input()
if last ="ABC":
  print"ARC"
else:
  print"ABC"

Submission status: Runtime Error

Solution code:
S = imput()

if S is 'ARC':
  print('ABC')
else:
  print('ARC')

Submission status: Runtime Error

Solution code:
inputStr = input()

if inputStr == 'ABC':
	print('ARC')
else if inputStr == 'ARC':
    print('ABC')
else:
	print('')

Submission status: Runtime Error

Solution code:
inputStr = input()

if inputStr == 'ABC':
  print('ARC')
else if inputStr == 'ARC':
  print('ABC')
else:
  print('')

Submission status: Runtime Error

Solution code:
inputStr = input()

if inputStr == 'ABC':
  return 'ARC'
else if inputStr == 'ARC':
  return 'ABC'
else:
  return null

Submission status: Runtime Error

Solution code:
input = input()

if input = 'ABC':
  return 'ARC'
else:
  return 'ABC'

Submission status: Runtime Error

Solution code:
if S is 'ABC':
	print('ARC')
elif S is 'ARC':
    print('ABC')

Submission status: Runtime Error

Solution code:
def next_contest(x):
  if x is 'ABC':
    return 'ARC'
  elif x is 'ARC':
    return 'ABC'
  else:
    return 'not defined contest'

next_contest(S)

Submission status: Runtime Error

Solution code:
S = input()
if S == "ABC":
    print(ARC)
else:
    print(ABC)

Submission status: Runtime Error

Solution code:
S = input()
if S == ABC:
    print(ARC)
else:
    print(ABC)

Submission status: Runtime Error

Solution code:
X = int(input())
for i in range(-200, 200):
    for j in range(-200, 200):
        if i**5 - j**5 == X:
            print(i,j)
            exit()

Submission status: Runtime Error

Solution code:
n, m = list(map(int, input().split()))
hs = list(map(int, input().split()))
ans = [1]*n
for i in range(m):
    road = list(map(int, input().split()))
    if hs[road[0]-1] <= hs[road[1]-1]:
        ans[road[0]-1] = 0
    if hs[road[0]-1] >= hs[road[1]-1]:
        ans[road[1]-1] = 0
print(ans.count(0))

Submission status: Runtime Error

Solution code:
a=raw_input()
if a=='ABC':
    print 'ARC'
else:
    print 'ABC'

Submission status: Runtime Error

Solution code:
a=raw_input()
if a=='ABC':
    print 'ARC'
elif a=='ARC':
    print 'ABC'

Submission status: Runtime Error

Solution code:
if S == 'ABC':
  print('ARC')
else:
  print('ABC')

Submission status: Runtime Error

Solution code:
a=raw_input()
print a
if a=='ABC':
  return 'ARC'
return 'ABC'

Submission status: Runtime Error

Solution code:
a=raw_input()
if a=='ABC':return 'ARC'
return 'ABC'

Submission status: Runtime Error

Solution code:
s = char(input())
if s=="ABC":
    print("ARC")
else:
    print("ABC")

Submission status: Runtime Error

Solution code:
x=int(input())
A=0
B=0
for a in range(-120,120):
    for b in range(-500,500):
        if a**5-b**5==x:
            A=a
            B=b
            break
print(A,B)

Submission status: Runtime Error

Solution code:
x=int(input())
A=0
B=0
for a in range(-500,500):
    for b in range(-500,500):
        if a**5-b**5==x:
            A=a
            B=b
            break
print(A,B)

Submission status: Runtime Error

Solution code:
A, B = map(int, input().split())
D = []
E = set()
total = A
for i in range(B):
    C = int(input())
    D = map(int, input().split())
    E.add(D)
for i in range(1, A+1):
  if str(i) in str(E):
    total = total - 1
print(total)

Submission status: Runtime Error

Solution code:
X = int(input())

for a in range(-120, 120):
    a5 = a**5
    for b in range(-120, 120):
        if a5 - b**5 == X:
            print(a, b)
            break

Submission status: Runtime Error

Solution code:
A, B = map(int, input().split())
D = set()
E =[]
total = A
for i in range(B):
    C = int(input())
    D = map(int, input().split())
    E.append(list(D))
for i in range(1, A+1):
  if str(i) in str(E):
    total = total - 1
print(total)