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

int solve(int n) {
    int a = n % 39;
    if (a == 0) a += 39;
    return a;
}

int main() {
    int n;
    while (cin >> n) {
        printf("3C%02d\n", solve(n));
    }
    return 0;
}