n = int(eval(input()))

ans = n*('ACL')

print (ans)
print((int(eval(input()))*'ACL'))
n = int(eval(input()))
ans = n * ("ACL")
print(ans)

print((int(eval(input())) * "ACL"))

-n = int(eval(input())) -ans = n * ("ACL") -print(ans) +print((int(eval(input())) * "ACL"))