Hello guys,
So I just finished my Bulls and Cows game, I even added difficulty settings and 10 difficult random words for each difficulty setting. Its almost complete except for this annoying bug which I cant seem to remove. I dont know how to explain it but I will try my best.
So when I start my game and choose the difficulty setting and as soon as I press enter, the game automatically takes a Guess input even though I dont input anything. I think it takes in a blank space ("") and returns the sentence “Please enter a 3 letter word”.
Here is a screenshot:
Here’s the github link to my code:
Please help me to fix this and also when you do let me know what was causing it.
Thanks a bunch
P.S. While your at it your more than welcome to go ahead and give my game a try, its a bit challenging . Don’t forget to tell me how the game is though .
SOLUTION: Used std::getline instead of std::cin