import math,sys,string for n in sys.stdin: s,n="",int(n);m=int(math.log(n,37)) while m+1:c=37**m;d=n/c;s+=string.printable[d];n-=d*c;m-=1 print s