#include <iostream>
using namespace std;
int main(void){
  int n,a;
  while(cin>>n){
    a=n%39;
    if(a == 0)
         a=39;
    cout<<"3C";
    if(a<10)
    cout<<"0";
    cout<<a<<endl;
    }
    return 0;
  }
