#include <iostream>
using namespace std;

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