Oops, try again. get_cl@ss_average([alice]) returned 83.8666666667 instead of 91.15 as expected


#1

Student Becomes Teacher ::Part of the whole
https://www.codecademy.com/courses/python-beginner-en-qzsCL/1/4?curriculum_id=4f89dab3d788890003000096

I keep getting the error "Oops, try again. get_class_average([alice]) returned 83.8666666667 instead of 91.15 as expected"

I have checked several responses to this problem and yet i still get the same error.
My code looks exactly like the ones that have resolved the problem,yet i still get the message.
What could possibly be going wrong here? Please assist,Thank you

I have lined up the For and the Return statements , but still get the same problem

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

#2

Hi @devplayer98062,

You have student as the parameter here, where you should have students ...

def get_class_average(student):

#3

Makes perfect sense.Thanks for quick response.!
All is working now


#4