Skip to content
Advertisement

Convert time interval given in seconds into more human readable form

I need a code snippet for converting amount of time given by number of seconds into some human readable form. The function should receive a number and output a string like this:

JavaScript

No formatting required, hard-coded format will go.

Advertisement

Answer

With help of Royi we’ve got code that outputs time interval in a human readable form:

JavaScript
User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement