I have some dates which format is d/m/yyyy (e.g. 2/28/1987).
I would like to have it in the ISO format : 1987-02-28
I think we can do it that way, but it seems a little heavy:
str_date = '2/28/1987'
arr_str = re.split('/', str_date)
iso_date = arr_str[2]+'-'+arr_str[0][:2]+'-'+arr_str[1]
Is there another way to do it with Python?