It's OK to be Average


Oops, try again. average([3, 0]) returned 3 instead of 1.5 as expected.

I don't understand what I'm doing wrong

def average(numbers):
    return sum(numbers)
    total = numbers
    return float(total)
    total / len(numbers)
    return total


Never mind, I figured it out.


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