Ofcourse!ThisisaclassicandveryimportanttopicinPython,especiallyforthosewhohaveworkedwithbothPython2...
这是一个非常经典的问题,主要涉及到Python2和Python3的区别,核心结论(一句话总结)在Python2中:range返回一个列表,而xrange返回一个xrange对象(一个轻量级的迭代器),在Pyth...