All problems

Problem 768

Seconds to Clock Time

Easy · 10 pts · Math, Basics, String

Problem

Convert a number of seconds S into hours, minutes and seconds, and print it in the format HH:MM:SS, where each part has exactly two digits (add a leading zero when needed). One hour has 3600 seconds and one minute has 60. The total is always less than 100 hours, so the hours also fit in two digits.

Input

A single integer S.

Output

Print the time as HH:MM:SS.

Constraints

0 <= S < 360000

Example input

3725

Example output

01:02:05

Explanation

3725 seconds is 1 hour (3600 s), 2 minutes (120 s) and 5 seconds, so the answer is 01:02:05.

Every problem here can be used in a RelayTrixCode team match. Create a room.

Previous: Minutes to Hours and Minutes Next: Rectangle Area and Perimeter