using System;

namespace Hi
{
    class Program
    {
        static void Main()
        {
            int x = int.Parse(Console.ReadLine());
            int h = 0, m = 0, s = 0;

            while (x >= 3600)
            {
                x -= 3600;
                h++;
            }

            while (x >= 60)
            {
                x -= 60;
                m++;
            }

            Console.WriteLine("{0}:{1}:{2}",h,m,s);

        }
    }
}