#include<iostream>
using namespace std;

int main()
{
    int n;

    while( cin >> n )
    {
        cout << "3C";
        if( n % 39 == 0 )
            cout << "39" << endl;
        else if( n % 39 < 10 )
            cout << "0" << n % 39 << endl;
        else
            cout << n % 39 << endl;
    }
    return 0;
}
