def solve(): N = int(input()) print(N * (N + 1)) T = int(input()) for _ in range(T): solve()