function main() {
	S = input[0];
	h = parseInt(S / 3600);
	m = parseInt(S / 60 % 60);
	s = parseInt(S % 60);

	msg = h + ':' + m + ':' + s;

	console.log(msg);
}

var input = "";

process.stdin.resume();
process.stdin.setEncoding("utf-8");
process.stdin.on("data", function(chunk) {
	input += chunk;
});

process.stdin.on("end", function() {
	input = input.split("\n");
	main();
})