how to change todays date formate in python

42

>>> datetime.today().strftime('%Y-%m-%d-%H:%M:%S')
'2021-01-26-16:50:03'

Comments

Submit
0 Comments