n = int(input())

for i in range(1, n + 1):
    for p in range(2):
        print('{} {} {}'.format(i, (i**2) + p, (i**3) + p))
1b021bde62f92f61734f3ac059bcd6ba1b1e95af
<mask token>

<mask token>
for i in range(1, n + 1):
    for p in range(2):
        print('{} {} {}'.format(i, i ** 2 + p, i ** 3 + p))

n = int(input())
for i in range(1, n + 1):
    for p in range(2):
        print('{} {} {}'.format(i, i ** 2 + p, i ** 3 + p))

n = int(input())

for i in range(1, n + 1):
    for p in range(2):
        print('{} {} {}'.format(i, (i**2) + p, (i**3) + p))