A two pair is a five card hand with two of one value, two of another value,and one of a third value. Ex: AABBC. Looking online shows that the correct formulation is [(13c2)(4c2)(4c2)(11)(4)]/(52c5). I do not understand why you multiple (4c2) twice though.
The reasoning I tried to apply (incorrectly) was as follows: There are 13 ranks, 4 cards in each rank. Then there are 4c2 ways to get 2 cards of the same rank, for each of the 13 ranks. So for the first pair, we have 13*(4c2) ways to get the desired pair. Once we have that pair one of the ranks is now off limits, so there are only 12*(4c2) ways to get the second pair. And once we have that only 11 ranks remain for the fifth card, each with 4 possibilities, giving us 11*4 options for it. Thus, the total number of ways to get a two pair is 13*12*(4c2)(4c2)(4*11)/(52c5). This is a different value from the one above though. Also, while my method multiplies (4c2) twice as well, the reasoning for it seems to be different than in the method above.
Can someone please explain why the correct method works, and where my thinking has gone wrong?
EDIT: Corrected my final formula.