注意python里面的递归

在python里面,递归函数的最大深度是999

超过这个深度就会报错

修改方式

import sys

sys.setrecursionlimit(1000000)

你可能感兴趣的:(注意python里面的递归)