using System.Collections.Generic; using System; public class Hello { public static void Main() { var ans = new List(); string[] line = Console.ReadLine().Trim().Split(' '); var n = int.Parse(line[0]); var d = int.Parse(line[1]); var a = 0; var c = 0; var bmax = 2 * n - d; for (int i = 0; i <= bmax; i++) { if ((bmax - i) % 2 == 0) c = (bmax - i) / 2; a = n - i - c; if (a>= 0) ans.Add(getString(a, i, c)); } ans.Sort(); Console.WriteLine(ans[0]); } public static string getString(int a, int b, int c) => new string('A', b) + new string('B', a) + new string('C', c); }