#双层循环
def print_pic(n):
for i in range(1,n+1):
for j in range(1,i+1):
print("{} ".format(j),end="")
print()
while True:
try:
num=input()
print_pic(int(num))
except:
break
#双层循环
def print_pic(n):
for i in range(1,n+1):
for j in range(1,i+1):
print("{} ".format(j),end="")
print()
while True:
try:
num=input()
print_pic(int(num))
except:
break