Login and get codingLet's do another
datetime
processing Bite. Completeadd_todo
below that converts time units to future timestamps.Here is how it works with given default
start_time
ofNOW
:>>> from timer import add_todo, NOW >>> str(NOW) '2019-02-06 22:00:00' >>> add_todo("11h 10m", "Wash my car") 'Wash my car @ 2019-02-07 09:10:00' >>> add_todo("30d", "Code a Bite") 'Code a Bite @ 2019-03-08 22:00:00' >>> add_todo("5m 3s", "Go to Bed") 'Go to Bed @ 2019-02-06 22:05:03'See the docstring and tests for more output examples. Good luck and code more Python!
Will you be the 131st person to crack this Bite?
Resolution time: ~61 min. (avg. submissions of 5-240 min.)
Our community rates this Bite 4.83 on a 1-10 difficulty scale.
» Up for a challenge? 💪