Last active
August 29, 2015 13:58
-
-
Save Restuta/10404410 to your computer and use it in GitHub Desktop.
For Helen
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#Define a function calledget_class_average that has one argumentstudents. You can expect students to be a list containing your three students. | |
#First, make an empty list calledresults. | |
#For each student item in the classlist, calculate get_average(student) and then call results.append() with that result. | |
#Finally, return the result of callingaverage() with results. | |
def get_class_average(students): | |
results = {} //should be results = [] | |
for item in students: | |
results.append(get_average(item)) | |
return average(results) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment