dear pythonistats
as a newcomber I want to create a set of lists containing n items, for example n = 3: (['a','b','c'], ['a','d','e'].......). The sequence of items in each list should be different. If the letters 'a'........'z' are used and n = 3 there is a maximum of 301 lists.
The following code works only for lists containing 1 item:

import random
list = ['a', 'b', 'c', 'd',....... 'z']
random.shuffle(list)
for x in list:
    print x

how can I solve my task wit n items ?
Thank you for help, Marcus.

---
Diese E-Mail wurde von Avast Antivirus-Software auf Viren geprüft.
https://www.avast.com/antivirus

_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Reply via email to