#include <iostream>
using namespace std;
int n;
char a[1000];
int main()
{
int cnt = 0;
cin>>n;
while(n){
int tmp;
tmp = n%26;
if(tmp == 0){
tmp = 26;
}
a[cnt++] = tmp + 'A' - 1;
n = (n-tmp)/26;//进制
}
for(int i = cnt-1; i >= 0; i--)
{
cout<<a[i];
}
return 0;
}