def f(x): c = bin(x)[2:] c = "0"*(k-len(c)) + c return int(c[::-1],2) k = int(input()) print(*[f(i) for i in range(1,2**k)])