I have been considering a solver for Mastermind / Moo that can take a list of a player's guesses and the scores he received for each guess, and calculate the unique solution that satisfies all the guesses.
Each line on the input contains the player's guess, followed by the number of correct guesses (bulls), then the number of numbers that are correct but in the incorrect position (cows).
Example Input:
1122 2 0 3344 1 1 1234 1 2 3411 0 4
Example Output: 1143
(Warning: Example done without the help of a computer, so it could be incorrect).
A simpler challenge could be to calculate the score (number of bulls and cows) given a solution and a guess, but if you can do this, I think it is not much more effort to create a complete solver.
I think something could be done in the style of Mastermind / Moo.
See http://en.wikipedia.org/wiki/Mastermind_%28board_game%29 for the rules.
I will post some more info about what I think the challenge could be later...
I'd also like to see this challenge. The only problem is that it has to be interactive (solution provides a guess, server provides the answer, until the correct answer is found or a maximum number of guesses is reached). Alternatively, the input could be a list of guesses and how they were scored, and it's up to the solution to figure out what the answer is.
I much prefer the interactive version, but that might require some (extensive?) reworking of the judging script.
No, it's not possible to make the challenge interactive. Of course, we could make it possible!
I like the idea of giving it a set of moves and having to deduce the correct solution from that, although I have a feeling that generating the test cases might be difficult. What do you think?
See http://en.wikipedia.org/wiki/Mastermind_%28board_game%29 for the rules.
I will post some more info about what I think the challenge could be later...