import java.net.NetworkInterface; import java.util.*; public class Main { static long gcd(long a,long b){ return b == 0 ? a : gcd(b, a%b); } static long lcm(long a, long b){ return a*b/gcd(a, b); } static int[] dx = {1,0,-1,0}; static int[] dy = {0,1,0,-1}; public static void main(String[] args) { Scanner sc = new Scanner(System.in); long n = sc.nextLong(); String ans = ""; ans+=(char)((int)'A'+n%26); if(n<=25){ System.out.println(ans); return; } if(n==26){ System.out.println("AA"); return; } int ind = 1; while(n>=Math.pow(27, ind)) ind++; ind--; String unko=""; for(int i=ind;i>=1;i--){ unko+=(char)((int)'A'+(int)(n/Math.pow(26, i))+(ind==1?-1:-1)); n%=Math.pow(26, i); } System.out.println(unko+ans); } }