Answers for "python input int output weekday datetime"

1

python datetime weekday

from datetime import datetime
date_str='10-12-20'
datetime_object = datetime.strptime(date_str, '%m-%d-%y')
datetime_object.weekday()
Posted by: Guest on October-13-2020
1

python datetime get weekday name

import datetime
now = datetime.datetime.now()
print(now.strftime("%A"))
Posted by: Guest on December-31-2020

Code answers related to "python input int output weekday datetime"

Python Answers by Framework

Browse Popular Code Answers by Language