Step Two: Marina had several attempts, many of which looked very close. In most cases, the code was just a few lines away from achieving the desired output.
First Try: the for loop should be designed to pull each string entry out of the json list of strings.
In Mariana's, the date_object line looks like it aimed to convert the entire string at once. It was also missing the second variable to define the format of the strings passed through.
Second Try: super close! Again, the for loop should be designed to pull each string entry out of the json list of strings. Then, the first variable in the strptime( 'string passed in', 'format as Mariana wrote it')
Third Try: I see she may have tried to define the i as a variable to loop through the individual characters of the string.
Fourth / Fifth Try: Mariana should have created a new name for the new list to which she would append the converted strings (the "data" name was already assigned to the initial json file).
It seems the second step of the assignment could have been achieved with a variation of her steps combined, for example:
clean_data = [] #her new list
for entry in data: #grab each entry in json and run following commands
date_obj = datetime.strftime('entry', '%Y-%m-%d %H:%M:%S')
clean_data.append(date_obj)
Step One: looks good!
Step Two: Marina had several attempts, many of which looked very close. In most cases, the code was just a few lines away from achieving the desired output.
It seems the second step of the assignment could have been achieved with a variation of her steps combined, for example:
clean_data = [] #her new list
for entry in data: #grab each entry in json and run following commands date_obj = datetime.strftime('entry', '%Y-%m-%d %H:%M:%S') clean_data.append(date_obj)
@ghego, @craigsakuma, @kebaler