def ints; gets.split.map(&:to_i); end n, d = ints b = [d-n, 0].max a = d - b*2 c = n - a - b puts 'A'*a + 'B'*b + 'C'*c