Discuss / Python / 交作业

交作业

Topic source

家有憨兔

#1 Created at ... [Delete] [Delete and Lock User]
def mul(x,*y):
    sum = x
    for n in y:
       sum = sum*n
    return sum

家有憨兔

#2 Created at ... [Delete] [Delete and Lock User]

应该使用默认参数用法将y改为args


  • 1

Reply