So I have two lists in Python:
import random list_1 = ['1','2','3'] list_2 = ['4','5','6'] num = random.choice(list_1 or list_2)
This doesn't seem to work. How can I get a random number from either list 1 or list 2?
Aucun commentaire:
Enregistrer un commentaire