Alexa Mastermind Game
Simply say "Alexa, ask Mastermind Game to start game." then alexa will read out the welcome message.
If user don't know the rules of this game then he/she can ask Alexa "Help" and Alexa will read out the rules.
After the welcome message user need to say any four colors from red, yellow, green, blue, orange, purple, white and black, in a single line for example :
"red yellow red blue"
Alexa will check the user response and tell the user if they are correct or not by replying with 1 and 0.
In our example we assume secret pattern is "red white red white" when user said "red yellow red blue", Alexa will say 1 0 1 0, which means place one and three are correct where are place two and four are not.
User need to keep on trying till he/she guess the correct pattern.
After guessing the correct pattern Alexa will tell the number of trials user took to guess it.
In the game of mastermind you need to guess Alexa's four color secret pattern by saying any four color names from red, yellow, green, blue, orange, purple, white and black.
Please note that there can be identical colors in the pattern. For each of your four response Alexa will tell you a number which is either 0 or 1, where 1 means your response is correct at the correct position and 0 which means your response is incorrect.
For example if the secret pattern is red, yellow, blue, red, and you said red, white, blue, red, then Alexa will say 1, 0, 1, 1.
The goal here is to minimize the number of trials to guess the correct pattern. If you are playing for the first time then grabbing a pen and a paper will be handy.
Log in or sign up for Devpost to join the conversation.