'use strict';
var Main = function(stdin) {
  var line = stdin.split('\n');
  var result = (function(sec) {
    return [
    	~~(sec / (60 * 60))
    	,~~((sec % (60 * 60)) / 60)
    	,(sec % 60)
    ].join(':');
  }(
  	parseInt(line[0],10)
  ));
  console.log(result);
};

Main(require('fs').readFileSync('/dev/stdin', 'utf8'));