n = input() nr = n[::-1] ans = "" for i in range(len(nr)): ans += nr[i] #print(ans,i) if i != len(nr)-1 and i % 3 == 2: ans += "," print(ans[::-1])