import Control.Applicative

hours :: Int -> Int 
hours x = div x 3600

minute :: Int -> Int
minute y = div (mod y 3600) 60

second :: Int -> Int
second z = mod (mod z 3600) 60

main = do
	a <- read <$> getLine
	putStrLn $ show (hours a) ++ ":" ++ show (minute a) ++ ":" ++ show (second a)
