Create a Countdown Timer with Python
- The
divmod()method takes two numbers and returns a pair of numbers (a tuple) consisting of their quotient and remainder. end='\r'overwrites the output for each iteration.- The value of
time_secis decremented at the end of each iteration.