#include <iostream>
#include <iomanip>

using namespace std;

int main()
{
    int n;
    while( cin >> n ) {
        int const nn = n % 39;
        cout << "3C" << setw(2) << setfill('0') << ( nn == 0 ? 39 : nn ) << endl;
    }

}