Separating Coin Piles with Equal Heads
Dividing coins into two equal heads is a medium quant interview question on Brain Teasers.
This brain teaser asks you to work with a large collection of indistinguishable coins, some heads and many tails, while blindfolded. Your task is to split them into two piles so that both piles end up containing the same number of heads, even though you have no information about which coins are which. You are allowed to flip any coins you like before finalizing the two groups. Variants of this puzzle appear in general brainteaser interviews and logic-focused assessments, especially where interviewers want to see structured reasoning under uncertainty.
Solving it leans on reasoning about invariants and conservation of a discrete quantity rather than on probability or guesswork. You need to recognize how a symmetric operation like flipping interacts with the unknown distribution of heads and tails, and how to turn that lack of information into something that actually does not matter. Interviewers watch for a clear logical argument, the ability to abstract away from the specific numbers, and an explanation that is robust to any initial configuration, not just a lucky one.
What it tests
This problem class is governed by the principle of conservation and transformation of discrete quantities under symmetric operations. When the total number of a certain property (like heads) is fixed and you can partition the set arbitrarily, you can use operations (like flipping) that invert the property to redistribute it between groups in a controlled way. The key is that flipping is an involution: it swaps heads and tails, so the number of heads in a group after flipping is equal to the number of tails before. By choosing the group size to match the total number of heads, you ensure that the transformation can always balance the distribution, regardless of the initial arrangement. The underlying structure is that the sum of the property across all groups remains constant, and you can manipulate the partition and transformation to achieve equality.
Practise this question with written feedback, or hear it in a spoken mock interview.
Get started free