Player A thinks of a four digit number, for example, 1863, and writes it down. The digits all have to be different. Player B then guesses what this secret number might be by saying any four digit number, for example 8962.
Player A reveals how close this guess is by saying how many cows and bulls have been scored. A cow means that the guess contains a correct digit but in the wrong position. A bull means that the guess contains a correct digit in the right position. So 8962 would be one cow and one bull. Player B uses this information to guess again with Player A revealing how many cows and bulls are scored.
The game continues until Player B identifies four bulls. Players then swap over. The player who finds the secret number with the fewest guesses wins. Try playing with six digits instead of four and work out the minimum number of moves needed to win.
John Dabell is a teacher at Lawn Primary School in Derby.