import java.util.Scanner;
public class Main{
    public static void main(String argv[])
    {
	Scanner scan = new Scanner(System.in);

	int num = scan.nextInt();
	int h=0,m=0,s=0;

	while(true)
	    {
		if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		}
	    }
	System.out.println(h+":"+m+":"+s);

    }
} import java.util.Scanner; Scanner java.util public class Main{
    public static void main(String argv[])
    {
	Scanner scan = new Scanner(System.in);

	int num = scan.nextInt();
	int h=0,m=0,s=0;

	while(true)
	    {
		if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		}
	    }
	System.out.println(h+":"+m+":"+s);

    }
} Main public static void main(String argv[])
    {
	Scanner scan = new Scanner(System.in);

	int num = scan.nextInt();
	int h=0,m=0,s=0;

	while(true)
	    {
		if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		}
	    }
	System.out.println(h+":"+m+":"+s);

    } main {
	Scanner scan = new Scanner(System.in);

	int num = scan.nextInt();
	int h=0,m=0,s=0;

	while(true)
	    {
		if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		}
	    }
	System.out.println(h+":"+m+":"+s);

    } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int num = scan.nextInt(); num scan.nextInt() scan.nextInt scan int h=0 h 0 m=0 m 0 s=0; s 0 while(true)
	    {
		if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		}
	    } true {
		if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		}
	    } if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		} num - 3600 >= 0 num - 3600 num 3600 0 {
			num = num-3600;
		    h++;
		    } num = num-3600 num num-3600 num 3600 h++ h if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		} num - 60 >= 0 num - 60 num 60 0 {
			num = num-60;
			m++;
		    } num = num-60 num num-60 num 60 m++ m {
		        if( num == 0) break;
			s++;
			num--;
		} if( num == 0) break; num == 0 num 0 break; s++ s num-- num System.out.println(h+":"+m+":"+s) System.out.println System.out System System.out h+":"+m+":"+s ":" m h+":"+m+":"+s h ":" m ":" s String argv[] argv public class Main{
    public static void main(String argv[])
    {
	Scanner scan = new Scanner(System.in);

	int num = scan.nextInt();
	int h=0,m=0,s=0;

	while(true)
	    {
		if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		}
	    }
	System.out.println(h+":"+m+":"+s);

    }
} public class Main{
    public static void main(String argv[])
    {
	Scanner scan = new Scanner(System.in);

	int num = scan.nextInt();
	int h=0,m=0,s=0;

	while(true)
	    {
		if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		}
	    }
	System.out.println(h+":"+m+":"+s);

    }
} Main
import java.util.Scanner;
public class Main{
    public static void main(String argv[])
    {
	Scanner scan = new Scanner(System.in);

	int num = scan.nextInt();
	int h=0,m=0,s=0;

	while(true)
	    {
		if( num - 3600 >= 0 )
		    {
			num = num-3600;
		    h++;
		    }
		else if( num - 60 >= 0 )
		    {
			num = num-60;
			m++;
		    }
		else {
		        if( num == 0) break;
			s++;
			num--;
		}
	    }
	System.out.println(h+":"+m+":"+s);

    }
}