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