#include <iostream>
#include <string>
using namespace std;

int main() {
	int a,b,c;
	while(cin >> a){
		b=a/39;
		c=a-b*39;
		cout << "3C";
		if(c==0){
			cout << "39" <<endl;
		}else if(c<10){
			cout << "0" << c <<endl;
		}else{
			cout << c << endl;
		}
	}
	return 0;
}