'use strict';
(function(stdin) {
  var lines  = stdin.toString().split('\n');
  var result = (function(sec) {
    return [
        ~~(sec / (60 * 60))
        ,~~((sec % (60 * 60)) / 60)
        ,(sec % 60)
    ].join(':');
  }(parseInt(lines[0])
  ));
  console.log(result);
}(require('fs').readFileSync('/dev/stdin', 'utf8')));