Please note, this is a STATIC archive of website www.tutorialspoint.com from 11 May 2019, cach3.com does not collect or store any user information, there is no "phishing" involved.
# Hello World program in Python
import random
players = { "rank1": ["Yuri","Noam","Oren"],
"rank2": ["Dani","Boaz","Omer"],
"rank3": ["Yoni","Lior","Eyal"],
"rank4": ["Jacob","Jonathan","Kobi"],
"rank5": ["leonid","Idan","Adi"]
}
all = []
for key in players:
random.shuffle(players[key])
all += players[key]
for i in range(0,3):
print "Group {} is {}".format(i+1,all[i::3])
Advertisements
We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy.
AcceptLearn more