def prod(L): def mul(s1,s2): return int(s1)*int(s2) #这里用了int函数,没有使用dic,感觉更快 return reduce(mul,L)
Sign in to make a reply
格林匹思
def prod(L): def mul(s1,s2): return int(s1)*int(s2) #这里用了int函数,没有使用dic,感觉更快 return reduce(mul,L)