#coding:utf-8

#1_1_D 2015.3.6

second = int(eval(input()))

hour = second // 3600

minutes = (second // 60) % 60

second %= 60

print(("%s:%s:%s" %(hour,minutes,second)))
#coding:utf-8

#1_1_D 2015.3.6

second = int(eval(input()))

hour = second // 3600

minutes = (second // 60) % 60

second %= 60

print(("{}:{}:{}".format(hour,minutes,second)))
# coding:utf-8
# 1_1_D 2015.3.6
second = int(eval(input()))
hour = second // 3600
minutes = (second // 60) % 60
second %= 60
print(("%s:%s:%s" % (hour, minutes, second)))

# coding:utf-8
# 1_1_D 2015.3.6
second = int(eval(input()))
hour = second // 3600
minutes = (second // 60) % 60
second %= 60
print(("{}:{}:{}".format(hour, minutes, second)))

-print(("%s:%s:%s" % (hour, minutes, second))) +print(("{}:{}:{}".format(hour, minutes, second)))