# -*- coding utf-8 -*-

S = int(eval(input()))

h = S // (60 * 60)

m = (S % 3600) // 60

s = (S % 3600) % 60

desc = "{0}:{1}:{2}".format(h,m,s)

print(desc)
# -*- coding: utf-8 -*-

S = int(eval(input()))



hour = int(S / (60 * 60))

minutes = int((S % (60 * 60)) / 60)

seconds = int((S % (60 * 60)) % 60)



watch = str(hour) + ":" + str(minutes) + ":" + str(seconds)



print(watch)

# -*- coding utf-8 -*-
S = int(eval(input()))
h = S // (60 * 60)
m = (S % 3600) // 60
s = (S % 3600) % 60
desc = "{0}:{1}:{2}".format(h, m, s)
print(desc)

# -*- coding: utf-8 -*-
S = int(eval(input()))
hour = int(S / (60 * 60))
minutes = int((S % (60 * 60)) / 60)
seconds = int((S % (60 * 60)) % 60)
watch = str(hour) + ":" + str(minutes) + ":" + str(seconds)
print(watch)

-# -*- coding utf-8 -*- +# -*- coding: utf-8 -*- -h = S // (60 * 60) -m = (S % 3600) // 60 -s = (S % 3600) % 60 -desc = "{0}:{1}:{2}".format(h, m, s) -print(desc) +hour = int(S / (60 * 60)) +minutes = int((S % (60 * 60)) / 60) +seconds = int((S % (60 * 60)) % 60) +watch = str(hour) + ":" + str(minutes) + ":" + str(seconds) +print(watch)