[Tutor] formatting datetime.timedelta to "HH:MM:SS"

Danny Yoo dyoo at hashcollision.org
Wed Dec 11 18:52:27 CET 2013


For reference, you can also see:

    http://stackoverflow.com/questions/8906926/formatting-python-timedelta-objects

which shows a similar approach.  The accepted solution there uses the
divmod() function to simplify a little bit of the math.


More information about the Tutor mailing list