mirror of
https://github.com/kennethreitz/python-guide.git
synced 2026-06-05 23:00:18 +00:00
Merge pull request #669 from kuldeeps48/master
A note for xrange() use in Python 3. Issue #665
This commit is contained in:
@@ -350,6 +350,8 @@ Instead, use a list comprehension:
|
||||
.. code-block:: python
|
||||
|
||||
four_lists = [[] for __ in xrange(4)]
|
||||
|
||||
Note: Use range() instead of xrange() in Python 3
|
||||
|
||||
Create a string from a list
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
||||
Reference in New Issue
Block a user