N=input() b=2 exec"n=N;r=''\nwhile n:r=chr(48+n%b+39*(n%b>9))+r;n/=b\nprint r;b+=1;"*35