+ 1
How I can make a list or some type of this from 1 to 50 to don't write all 1,2,3,4...
To use this list in future with Random function
2 Réponses
+ 3
var=list(range(1,51))
0
If you plan on using the list for random selection,
randint (1,51) is a much better way to achieve. Just import it from random module using
from random import randint