Skip to content

Instantly share code, notes, and snippets.

@garrypolley
Last active November 13, 2016 16:23
Show Gist options
  • Save garrypolley/a71f8bf00b4313b9d037faed4121d317 to your computer and use it in GitHub Desktop.
Save garrypolley/a71f8bf00b4313b9d037faed4121d317 to your computer and use it in GitHub Desktop.
Determines who gets what house
import random
people_playing = ['Garry', 'Joanna', 'Sara', 'Mark', 'Phil', 'Tom']
families = ['Stark', 'Greyjoy', 'Dorne', 'Tyrell', 'Lannister', 'Baratheon']
chosen_families = {}
for person in people_playing:
family = random.choice(families)
chosen_families[person] = family
families.remove(family)
for person, family in chosen_families.items():
print(person, 'is assigned', family)
@markdcummings
Copy link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment