range([start], stop[, step]):产生一个序列,默认从0开始
>>> l = range(10) >>> l [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] >>> L = range(3,10) >>> L [3, 4, 5, 6, 7, 8, 9] >>> LL = range(1,23, 2) >>> LL [1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21] >>>
range([start], stop[, step]):产生一个序列,默认从0开始
>>> l = range(10) >>> l [0, 1, 2, 3, 4, 5, 6, 7, 8, 9] >>> L = range(3,10) >>> L [3, 4, 5, 6, 7, 8, 9] >>> LL = range(1,23, 2) >>> LL [1, 3, 5, 7, 9, 11, 13, 15, 17, 19, 21] >>>