# Part of the whole - Just wondering

#1

Hi people!

First, I finished this exercise with only minor complication. As much as I checked the forum, this was quite common. I put the list students = [lloyd, alice, tyler] in the function get_class_average (like so

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

I tried a few things, like deleting that list, and it worked. But then I wondered, how come the function get_class_average know who these students are if we didn't define the list students anywhere?

Much thanks to all who take time for this question

#2

well you define the students list in 3. put it together. But it seems that in one of the lessons, the list gets lost.

In the next exercise you will add a function call. When adding a function call, you will supply an argument to satisfy the function parameter students

You don't have to satisfy function parameters until you call the function. parameters are "only" placeholders

#3

ah I see, thank you very much

(so i did a quick test to confirm i understand what you ment
salami = [lloyd, alice, tyler]

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

print get_class_average(salami)
print