#include <iostream>
#include <iomanip>

using namespace std;

void solve(int n){
    n = n % 39;
    if(n==0) n =39;
    cout << "3C";
    cout << setw(2) << setfill('0') << n << endl;
}
int main(){
    int n;
    while(cin >> n){
        solve(n);
    }
}