H
Howard
Hello everyone (total VB.NET beginner here),
I'm reading the "SAMS Teach Yourself VB.NET In 21 Days" book, and came
across an exercise that I can't get to work. The exercise asks that
you create a game that makes the user guess a number from 1-100, and
you tell the user "lower" or "higher" as they input their guesses,
until they guess the correct number, at which point you then tell the
user "Correct". I tried using the While Loop, and it "sort of" worked,
but after a while (no pun intended) of inputting numbers (guesses), it
said "Correct" to incorrect answers.
The chapter was discussing different types of loops among other things,
and I'm guessing that they want us to use a While Loop for this
exercise. If anyone has the book, it's at the end of day two (page
101).
Please let me know of any suggestions you may have.
Thank you very much.
Howard
I'm reading the "SAMS Teach Yourself VB.NET In 21 Days" book, and came
across an exercise that I can't get to work. The exercise asks that
you create a game that makes the user guess a number from 1-100, and
you tell the user "lower" or "higher" as they input their guesses,
until they guess the correct number, at which point you then tell the
user "Correct". I tried using the While Loop, and it "sort of" worked,
but after a while (no pun intended) of inputting numbers (guesses), it
said "Correct" to incorrect answers.
The chapter was discussing different types of loops among other things,
and I'm guessing that they want us to use a While Loop for this
exercise. If anyone has the book, it's at the end of day two (page
101).
Please let me know of any suggestions you may have.
Thank you very much.
Howard