# Wrong Answer: 間違えてtも出力したパターン t = int(input()) for i in range(t): n = int(input()) print("ABACBC" + (n - 2) * "ABC")