num = input() num = num[::-1] newnum = "" for i in range(0, len(num)): if i == 0: newnum += num[i] elif i % 3 == 0: newnum += "," newnum += num[i] else: newnum += num[i] print(newnum[::-1])