Hands-on task
This task is step 7 of the course “Dates and times in the terminal”
Seconds to HH:MM:SS
The file /root/seconds.txt holds a duration in seconds (less than a day). Represent it in the HH:MM:SS format with leading zeros — for example, 3725 seconds is 01:02:05 — and write the result to /root/dur.txt. The sandbox's system time zone is Europe/Berlin, not UTC.
Reference:date
What you'll practise:
- date
- -u
- epoch
- %T
- duration