n = int(input()) + 1 s = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" l="" while n: n -= 1 l += s[n%26] n //= 26 print(l[::-1])