from datetime import datetime dob = "56-01-02" # Parse the string date into a datetime object date_object = datetime.strptime(dob, "%Y-%m-%d") # Format the date object using strftime formatted_date = date_object.strftime("%B %d, %Y") # Print the formatted date print(formatted_date)