#include using namespace std; typedef long long ll; string AtoZ; int main() { ll N; cin >> N; list lst; for(char ch='A'; ch<='Z'; ch++){ AtoZ.push_back(ch); } ll cnt=0; while(1){ ll x; x = N%26; N /= 26; if(cnt++==0) lst.push_front(AtoZ[x]); else lst.push_front(AtoZ[x-1]); //cout << N <<" "<< x << endl; if(N==1){ lst.push_front('A'); break; } if(N==0) break; } for(auto itr=lst.begin(); itr!=lst.end(); itr++){ cout << *itr; } cout << endl; }