×   Home   Blog   Newsletter   Privacy   Contact Us   About

Gender Identification Puzzle

You are sent on a mission to buy two new chicks. The mandate is clear – return with two chicks; one male, and one female.
You enter the supply store and the shopkeeper points you to a cage in which there are a dozen chicks. He tells you that half of them are male, half are female, and to help yourself. The problem, however, is that you are not an ornithologist, and all the chicks look the same to you. You can’t tell which are male and which are female.
You ask for assistance, and the shopkeeper (who happens to be an expert in the gender classification of chickens) offers to help. He says that you can bring any set of chicks to him and he will tell you how many males are in that batch (without individually identifying any of them; just telling you the count of males in that set).
What strategy should you employ to efficiently obtain a pair of chicks (one male, and one female) using the smallest number of identification events? Using this strategy, what is the worst case for the number of times that you will need to ask the shopkeeper for help?
What strategy should you employ to efficiently obtain a pair of chicks?
Sure, you could bring them out individually, and the first chicken is a gimmie, but finding the opposite gender for the second chick is down to luck. You could get it on your first try, but it might take up to another six tries to find an opposite.
If you brought half to the shopkeeper, unless you were very lucky and picked all the same gender, you’d then have to worry about how to identify a pair from the six you had.
There has to be a better (and more predictable) way …