阅读背景:

使用c++可执行文件:While循环和If/Else If/Else If/Else

来源:互联网 

So, for robotics, the programming team is learn a new language, C++ instead of Objective Robotic C, and in order to learn the language, we are creating our own Text Based Roleplaying Games. I have started creating mine and have run into an issue. I have to program ask for a Y or an N and then detect which one it is in order to move on with that game. The detection system is inside of a while loop, so that way if it gets an answer other than Y or N it will restart loop. However, when it runs it, it only seems to detect the N. Anything else I put in for the answer triggers the "Yes" option. I'm guessing it is something super obvious I am missing. Here's the code.So, for robotics, the programming team is learn




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: