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