Run
# Import datetime package import datetime # Set a date d = datetime.datetime(2019, 8, 12) # Print date print(d) # Get the weekday short version print(d.strftime("%a"))
Output