for _ in range(int(input())): l = int(input()) if l % 2: print(l, (l**2-1)//2, (l**2+1)//2) else: print(l, (l**2-4)//4, (l**2-4)//4+2)