const val MIN_THRESHOLD = 60
const val HR_THRESHOLD  = 60 * 60

fun main(args: Array<String>){
    val input: Int = readLine()?.toInt() ?: return
    val hr  = translateToHr(input)
    val sec = translateToSec(input)
    val min = (input - (hr * HR_THRESHOLD)) / MIN_THRESHOLD
    println("$hr:$min:$sec")
}

fun translateToHr(seconds: Int): Int  = seconds / HR_THRESHOLD
fun translateToSec(seconds: Int): Int = seconds % MIN_THRESHOLD
