• Advertisement
Sign in to follow this  

Guessing game help

This topic is 3420 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm programmin a guessing game on my 84 calc but its not working right can someone help me figure it out? Heres what i have so far... <-- noob at programming btw :ClrHome : :randInt(1,50)->X \\-> represents the sto> button : :If y\=x \\ \= is the not equal to symbol :Then :Repeat prgmGUESS :Input y :If Y=X :Then :Disp "You Win" : :Repeat prgmGUESS : :If Y<X :Then :Disp "A little Higher" : : : :If y>x :Then :Disp "A little Lower"

Share this post


Link to post
Share on other sites
Advertisement
You say its not working right. The easiest way to get a good answer is to describe fully what you mean by this. If you see an error message, you should post it in full. If the program acts erratically, describe what it is doing.

At a glance, I will say that your use of case is inconsistent. You change from using x to X and y to Y every few lines. Unless the language is case-insensitive that won't work. If it is case insensitive, it is still a bad habit. It is hard to read.

Share this post


Link to post
Share on other sites
When I run the program and test it out I enter in the variable and it ends the program saying Done, and its on my calculator i'm programming this so its all Capitals

:?9
Done

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement