[Tutor] war cards
alan.gauld at btinternet.com
Mon Dec 24 18:21:02 CET 2007
"max baseman" <dos.fool at gmail.com> wrote
> it i got stuck on one bit, how do i make it so that their is one of
> each card and i can split them?
You can define the cards as a tuple of values and insert them into a
You can use random.choice() to select a card fro the list.
By applying that repeatedly you can split the list across multiple
players hands(also lists)
Is that what you mean?
Author of the Learn to Program web site
More information about the Tutor