#include using namespace std; #define REP(i, n) for(int i = 0; i < (int)(n); i++) #define FOR(i,n,m) for (int i=n; i<(int)(m); i++) #define INF 1000000007 #define mp make_pair typedef long long ll; typedef long double ld; ll dy[4]={-1,1,0,0}; ll dx[4]={0,0,1,-1}; /*---------- template ----------*/ ll N; int main(){ cin >> N; ll t=1; ll s=0; int leng=0; FOR(i,1,10){ t*=26; s+=t; if(s >= N){ s-=t; N-=s; leng=i; break; } } string ans=""; while(N!=0){ int t=N%26; ans=char('A'+t)+ans; N/=26; } REP(i,leng-ans.size()){ ans=ans+'A'; } cout << ans << endl; return 0; }