#include #include int main() { char N[11]; scanf("%s", N); int l = strlen(N); int n = l % 3; if (n > 0) fwrite(N, 1, n, stdout); for ( ; n < l; n += 3) { if (n > 0) fwrite(",", 1, 1, stdout); fwrite(N+n, 1, 3, stdout); } fwrite("\n", 1, 1, stdout); return 0; }