python2与python3的区别

python2:

print可以不加()

有range  和  xrange:迭代器

python3:

print必须加()

只有range

python3:有nolocal    python2:只有globals

posted on 2018-01-25 14:58  刘。林  阅读(91)  评论(0编辑  收藏  举报

导航