Question

How to create and populate a list with the range() function in Python?


Annonce
Ad

Answer

>>> myList=list(range(10))
>>> myList
[0, 1, 2, 3, 4, 5, 6, 7, 8, 9]


[source]
# ID Query