#include #include #include #include #include #include #include #include #include #include #include #include #include #define repd(i,a,b) for (int i=(a);i<(b);i++) #define rep(i,n) repd(i,0,n) #define var auto #define mod 1000000007 #define inf 2147483647 #define nil -1 #define mp make_pair typedef long long ll; using namespace std; template inline void output(T a, int p) { if(p){ cout << fixed << setprecision(p) << a << "\n"; } else{ cout << a << "\n"; } } // end of template ll power(ll n, int p){ ll ret = 1; rep(i, p){ ret *= n; } return ret; } int main() { cin.tie(0); // source code ll N; cin >> N; int p = 1; while (N - power(26, p) >= 0) { N -= power(26, p); p++; } vector ret(p); rep(i, p){ ret[i] = (N / power(26, i)) % 26; ret[i]++; } reverse(ret.begin(), ret.end()); rep(i, ret.size()){ cout << char('A' + ret[i] - 1); } cout << endl; return 0; }