#include <iostream>
#include <algorithm>
using namespace std;
typedef long long ll;
ll x;
string s = "ZABCDEFGHIJKLMNOPQRSTUVWXYZ";
string ans;
int main(void){
scanf("%lld", &x);
while(x){
ans += s[x % 26];
x = (x - ((x % 26) + 26) % 27) / 26;
/*if(x % 26 == 0) x = (x - 26) / 26;
else x = (x - x % 26) / 26;*/
}
reverse(ans.begin(), ans.end());
cout << ans << endl;
return 0;
}