Finally, here is the reason why it works.
Let,
H=total # of heads up coins
x=number of unknown heads up coins we grabbed
So,
heads up coins in stack A = x
heads up coins in stack B = H-x
After flipping stack A we have
heads up coins in stack A = H-x
heads up coins in stack B = H-x
I don't know how good this explanation is, but it does make sense to me. When you flip stack A you get just the opposite of the number of heads ups coins than you grabbed. Also, since stack A contained H number of coins, it can't contain too many or too few coins (this is why flipping stack B won't work -- it doesn't have the right number of coins).
Maybe pdurrant can do a better job of explaining why it works than I have done.
One example with the mathematical explanation.
Suppose you have 100 coins and 15 are heads up. You grab 15 coins at random to form stack A. There are x number of heads up coins in this stack. Let's say that you had grabbed 3 of the heads up coins. Therefore, stack A contains 3 heads up coins, and stack B contains 12 heads up coins (15-3=12). When you flip stack A, which contains 15 coins, then your 3 coins that were heads become tails, and the 12 tails become heads. So, stack A goes from x heads up coins to H-x (15-3=12).
Last edited by Daithi; 04-07-2012 at 04:36 PM.
|