hour :: Int -> Int 
hour time = div time 3600

minute :: Int -> Int 
minute time = mod (div time 60) 60

second :: Int -> Int 
second time = mod time 60

main = do
  num <- readLn
  putStrLn (show (hour num) ++ ":" ++ show (minute num) ++ ":" ++ show (second num))