Answers for "time today in python"

1

use datetime python to get runtime

from datetime import datetime

start = datetime.now()
# code ...
print(datetime.now()-start)
Posted by: Guest on October-23-2020
0

python print datetime

import datetime
print("Now:", datetime.datetime.now())
Posted by: Guest on August-23-2020

Python Answers by Framework

Browse Popular Code Answers by Language