if __name__ == '__main__':

    time_in_second = int(eval(input()))



    hour = time_in_second // 3600

    minute = (time_in_second % 3600) // 60

    second = time_in_second % 60



    print(('{0:d}:{1:d}:{2:d}'.format(hour, minute, second)))
# -*- coding: utf-8 -*-

"""

http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ITP1_1_D&lang=jp



"""

import sys

from sys import stdin

input = stdin.readline





def main(args):

    S = int(eval(input()))

    h = S // 3600

    m = (S % 3600) // 60

    s = S % 60



    print(('{}:{}:{}'.format(h, m, s)))





if __name__ == '__main__':

    main(sys.argv[1:])

    
if __name__ == "__main__":
    time_in_second = int(eval(input()))
    hour = time_in_second // 3600
    minute = (time_in_second % 3600) // 60
    second = time_in_second % 60
    print(("{0:d}:{1:d}:{2:d}".format(hour, minute, second)))

# -*- coding: utf-8 -*-
"""
http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ITP1_1_D&lang=jp
"""
import sys
from sys import stdin

input = stdin.readline


def main(args):
    S = int(eval(input()))
    h = S // 3600
    m = (S % 3600) // 60
    s = S % 60
    print(("{}:{}:{}".format(h, m, s)))


if __name__ == "__main__":
    main(sys.argv[1:])

+# -*- coding: utf-8 -*- +""" +http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=ITP1_1_D&lang=jp +""" +import sys +from sys import stdin + +input = stdin.readline + + +def main(args): +    S = int(eval(input())) +    h = S // 3600 +    m = (S % 3600) // 60 +    s = S % 60 +    print(("{}:{}:{}".format(h, m, s))) + + -    time_in_second = int(eval(input())) -    hour = time_in_second // 3600 -    minute = (time_in_second % 3600) // 60 -    second = time_in_second % 60 -    print(("{0:d}:{1:d}:{2:d}".format(hour, minute, second))) +    main(sys.argv[1:])