ll@N,m=N,K=0;string S{};while(m>1&&K<=10000){K++;if(m%2==0)m/=2,S+="/";else m=m*3-1,S+="-";} if(m>1){m=N;K=0;S="";while(m>1){K++;if(m%2==0)m/=2,S+="/";else m=m*3+1,S+="+";}} assert(K<=10000); wtLn(K,S);