I have a command line program in Python that takes a while to finish. I want to know the exact time it takes to finish running.
I\'ve looked at the timeit
timeit
from time import time start_time = time() ... end_time = time() time_taken = end_time - start_time # time_taken is in seconds hours, rest = divmod(time_taken,3600) minutes, seconds = divmod(rest, 60)