import datetime as dt
current_dates = ['09 May 2020', '10 May 2020', '11 May 2020', '15 May 2020']
for item in current_dates:
date = item
date = dt.datetime.strptime(item, '%d %b %Y')
item = date
print(current_dates)
I'm trying to convert the items in the current_dates
list to datetime, but when I subsequently type type(current_dates[0]
the program returns str