I met this problem during an interview. This is a mathematical problem, but I'm not sure which field it belongs to:
There are 6 boxes, one of the boxes contains a ball. The color of the ball may be red, blue or green. Now, each time, you can guess the status of each box. For example, I put a blue ball in 3rd box. And if you guess: [Empty, Empty, Red, Empty, Empty, Empty] or [Empty, Blue, Blue, Empty, Empty, Empty], I will tell you that you guess 5 correct status. But if you guess [red, red, red, red, red, red], then you guess 0 correct status, but this pass you the information that the color of the ball is not red. If you guess [Empty, Empty, Blue, Empty, Empty, Empty], then I would tell you "Congratulation, you get the location and color of the ball!".
Please design an optimal strategy, so that the strategy ensures to take at most k times to guess the correct color and location of the ball for all possible case. Please also convince me why your strategy is optimal, that is, why k is the minimax guess times needed?
Could you generalize your conclusion into m boxes and n possible colors cases?
The above is the problem, seems quite easy, but I cannot convince myself. And what's the field of this kind of problems? Decision theory, operation research or anything else?
Thank you so much!!!