def f(n): cs = [] x = n + 1 while x > 0: x, m = divmod((x-1), 26) cs.append(chr(m + ord('A'))) return ''.join(reversed(cs)) N = int(input()) print(f(N))