标签:面试题 int average end def pytho pen bsp turn
def make_averager():
nums=[]
def averager(n):
nums.append(n)
return sum(nums)/len(nums)
return averager
averager = make_averager()
print(averager(10))
print(averager(20))
标签:面试题 int average end def pytho pen bsp turn
原文地址:https://www.cnblogs.com/renguiyouzhi/p/12335153.html