import sys input = sys.stdin.readline def S(n): i = 0 lis = [] while(n): if(n & 1): lis.append(i) i += 1 n >>= 1 ret = ["{"] for i, k in enumerate(lis): ret.append(S(k)) if(i == len(lis) - 1): break ret.append(',') ret.append("}") return ''.join(ret) N = int(input()) print(S(N))