N,D = map(int,input().split()) if N >= D: print('A'*D+'C'*(N-D)) else: print('A'*(2*N-D)+'B'*(D-N))