fun divMod(a: Int, b: Int): Pair<Int, Int> {
    val div = a / b
    val mod = a % b
    return Pair(div, mod)
}

fun main(args: Array<String>) {
    val S = readLine()!!.toInt()
    val (M, s) = divMod(S, 60)
    val (h, m) = divMod(M, 60)

    println("$h:$m:$s")
}

