N=int(input()) sosa="" cnt = 0 for i in range(10000): if N%2 == 0: N/=2 sosa=sosa+"/" else: if cnt%2 == 0: N=N*3+1 sosa=sosa+"+" else: N=N*3-1 sosa=sosa+"-" cnt += 1 if N==1: break print(len(sosa)) print(sosa)