import sys sys.setrecursionlimit(10**6) N = int(input()) def func(n): ans = [] if n == 0: return "{}" for i in range(n): if 2 ** i > n: break if 2 ** i & n != 0: ans.append(func(i)) return "{" + ", ".join(ans) + "}" print(func(N))