def ones(m): return bin(m).count('1') def expand(m, n): dm = ones(m) ms = [m - dm, m + dm] return [m for m in ms if 0 < m <= n] def bfs(frontier, visited, n): while frontier: path = frontier.pop(0) last = path[-1] if last == n: return path elif last not in visited: visited.add(last) for m in expand(last, n): frontier.append(path + [m]) n = int(raw_input()) path = bfs([[1]], set(), n) if path: print '->'.join(str(i) for i in path) else: print -1