python reduce 函数使用详解 reduce()函数在python2是内置函数,从python3开始移到了functools模块。官方文档是这样介绍的reduc python中reduce函数