Answers for "how to take the time of a python script"

3

how to time a python script

from datetime import datetime
start = datetime.now()
# some kind of code
print(datetime.now() - start)
Posted by: Guest on July-07-2020
1

time in python code

import datetime

x = datetime.datetime.now()

print(x)
Posted by: Guest on April-04-2021

Code answers related to "how to take the time of a python script"

Python Answers by Framework

Browse Popular Code Answers by Language