n=list(map(int,input())) n.sort() ans="" anw="" for i in n: ans+=str(i) n.reverse() for i in n: anw+=str(i) if int(ans)