#include<iostream>

using namespace std;


int main(){
	int candy,i,j;

	while(cin >> candy){
		while(candy > 39){
			candy = candy - 39;
		}

		if(candy>9){
			cout << "3C" << candy << endl;
		}else{
			cout << "3C0" << candy << endl;
		}
	}
}