vendredi 26 mars 2021

How do I create 4 different lists of random numbers without overlapping them using Python?

I need to create 4 lists of random numbers containing 6 numbers each, these numbers can't overlap. How can I do it? The below only generates 1 list. I need 4.

import random

list_numbers = [random.randint(8,28) for x in range(6)]
print(list_numbers)



Aucun commentaire:

Enregistrer un commentaire