8/9 Help please!


#1

What am I doing wrong ??
Here is my code(my indentation is right):
results = []
students = [lloyd, alice, tyler]

def get_class_average(students):
for indi in students:
results.append(get_average(indi))
return average(results)


#2

"Oops, try again. get_class_average([lloyd]) returned 85.85 instead of 80.55 as expected"


#3

You have to move definition of results array to the get_class_average function to wipe out content of array at the beginning of every function execution.


#4

that was the problem... thanks !


#5

You're very welcome :smile: