File tree Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Expand file tree Collapse file tree 1 file changed +8
-0
lines changed Original file line number Diff line number Diff line change 38
38
- [ 27 read,readline和readlines] ( #27-readreadline和readlines )
39
39
- [ 28 Python2和3的区别] ( #28-python2和3的区别 )
40
40
- [ 29 super.__ init__ ()] ( #29-super-init )
41
+ - [ 30 range-and-xrange] ( #30-range-and-xrange )
41
42
- [ 操作系统] ( #操作系统 )
42
43
- [ 1 select,poll和epoll] ( #1-selectpoll和epoll )
43
44
- [ 2 调度算法] ( #2-调度算法 )
@@ -667,6 +668,13 @@ Note that the syntax changed in Python 3.0: you can just say super().__init__()
667
668
668
669
http://stackoverflow.com/questions/576169/understanding-python-super-with-init-methods
669
670
671
+ ## 30 range and xrange
672
+ What is the difference between range and xrange functions in Python 2.X?
673
+ range creates a list, so if you do range(1, 10000000) it creates a list in memory with 9999999 elements.
674
+ xrange is a sequence object that evaluates lazily.
675
+
676
+ http://stackoverflow.com/questions/94935/what-is-the-difference-between-range-and-xrange-functions-in-python-2-x
677
+
670
678
# 操作系统
671
679
672
680
## 1 select,poll和epoll
You can’t perform that action at this time.
0 commit comments