#include <stdio.h>
#include <string.h>

int main()
{
char buf[256], out[290];
int i, ip=0, op = 0;

fgets( buf, 256, stdin );
i = strpbrk(buf,"\n.") - buf;

for( ; i>0; i-- ){
if( ( i % 3 ) == 0 )
out[op++] = ',';
out[op++] = buf[ip++];
}
out[op] = 0;
printf("%s\n", out );

return 0;
}