import scala.io.StdIn.readInt
object Main {
    def main(args: Array[String]) = {
        val a = readInt()
        println(watch(a))
    }
    def div(a: Int, b: Int): (Int, Int) = (a / b, a % b)
    def watch(sec: Int): String = {
        val a = div(sec, 3600)
        val b = div(a._2, 60)
        return s"${a._1}:${b._1}:${b._2}"
    }
}
