// import java.util.*; class Main { static Scanner sc = new Scanner(System.in); public static void main(String[] args) { StringBuilder sb = new StringBuilder(sc.next()); int length = sb.length(); for (int i=length-1; i>=1; i--) { if ((length-i)%3==0) sb.insert(i,","); } System.out.println(sb); } }