N = int(input()) ans = [] while N: r = N % 26 N //= 26 ans.append(chr(r + ord('A'))) print("".join(reversed(ans)))