Just for my own curiosity,


#1

def get_class_average(students):
results = []
for student in students:
results.append(get_average(student))
return average(results)

Just for my own curiosity, I want to understand. 1. How can I print the results list?
2. In the final return statement (return average(results) why can't you just simply put return results?


Part of the Whole,help!
#2

Because results is a list. We need a value, a class average.


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.