for _ in range(T := int(input())): N = int(input()) - 2 print("ABACBC" + "ABC"*N)