#include using namespace std; long long n; string s = ""; int main(){ cin >> n; if(n == 0){ cout << 'A'; return 0; } while(n > 0){ int t = n % 26; t += 65; char d = t; s += d; n /= 26; } for(int i = s.size() - 1;i >= 0;i--){ if(i == s.size() - 1){ cout << char(s[i] - 1); } else cout << s[i]; } cout << endl; return 0; }