n = input()[::-1] n2 = [n[i:i+3] for i in range(0, len(n), 3)] print(','.join(n2)[::-1])