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

int main() {
	int in, out, tmp;

	while (1) {
		if (scanf("%d", &in) == EOF) break;

		tmp = in / 39;
		out = in - (tmp * 39);
		printf("3C");
		if (out == 0) printf("39\n");
		else if (out < 10) printf("0%d\n", out);
		else printf("%d\n", out);
	}
}

