1) Poker is a card game that is based largely on 
probability. There are several kinds of 5 card 
``poker hands''. We've seen some of these in
class: one pair, two pairs, three of a kind, 
a straight, a flush, a full house (3 of a kind
and a pair), four of a kind, and a straight flush.
These hands are listed in increasing strength, and
also in decreasing probability.

A 5 card hand is considered equal to the \emph{best}
possible hand.
So, a hand that consists of ranks: (4,4,4,2,2) is
considered a full house even though it contains
three of a kind, two pair, and one pair. 

A deck consists of 52 cards, which consist of 
13 different ranks in 4 different suits. The four
suits are hearts, spades, diamonds, and clubs. 
The 13 ranks are: A,2,3,4,5,6,7,8,9,10,Jack,Queen,King
in increasing order. A flush consists of 5 cards of the
same suit, and a straight consists of 5 cards of consecutive
rank.

Here we examine what happens to poker when you have
a wild card. Assume (until otherwise noted) that
all 2's are wild. A wild card can be substituted
for any other card in the deck. It has the rank and
suit that best helps your hand.

a) How many 5 card poker hands are there such that
the best hand you can make is two pair. In other
words, you one pair of cards of a particular rank,
and another pair of cards of a particular rank, and
the fifth card does not match either of the pairs.
Careful, consider what happens if the hand contains
a wild card and a pair...

\solution{
Note that it is impossible to have 2 pair if you use
any wild cards. Therefore, we can only have pairs
of 12 different ranks.

$\binom{12}{3}*\binom{4}{2}*\binom{4}{2}*\binom{4}{1}$
}

b) How many 5 card poker hands are there such that the
best hand is three of a kind, but that DO NOT use a 
wild card?

\solution{
$\binom{12}{3}*\binom{4}{3}*\binom{4}{1}*\binom{4}{1}$
}

c) How many 5 card poker hands are there such that
the best hand is three of a kind that use one wild card?

\solution{
You can use at most two wild cards, with three wild cards
you could always make four of a kind.

One wild card: $\binom{4}{1}*\binom{12}{3}*\binom{4}{2}*\binom{4}{1}*\binom{4}{1}$

}

d) Why is it more difficult to count the number of 5 card poker
hands that use two wild cards? Hint: What other hands can be
made out of a hand containing two wild cards? Think inclusion-
Exclusion.

\solution{
It is possible that a 5 card poker hand with two wild cards 
can also make a flush or a straight.
}

e) Why are wilds generally not used in advanced forms of poker?
\solution{
Three of a kind beats two pair, even though it is more likely.
}
