import           Control.Applicative

main :: IO ()
main = do
    x0 <- readLn
    let (x1, s) = x0 `divMod` 60
        (h,  m) = x1 `divMod` 60
    putStrLn $ show h ++ ":" ++ show m ++ ":" ++ show s