alp = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" N = int(input()) ans = alp[N % 26] N //= 26 while N > 0: ans += alp[N % 27] N //= 27 print(ans[::-1])