Search:

Type: Posts; User: GregBrannon

Search: Search took 0.11 seconds.

  1. Re: while loop loops foreve even with the right inputs.

    His response had 2 suggestions, not necessarily meant to be taken together:

    Suggestion 1: Change || to &&

    Suggestion 2: Change the design from a while to a do/while

    His Suggestion 2...
  2. Re: while loop loops foreve even with the right inputs.

    What was the wrong with PhHein's suggestion to use && instead of ||? Did you try that?

    Edit: And why not use 'U' for Up and 'D' for down (or similar)? The Y/N logic to indicate the user's...
  3. Re: while loop loops foreve even with the right inputs.

    Here's how I read your explanation:

    User enters:

    'Y' = loop quits (exits)
    'N' = loop quits (exits)
    Any character other than 'Y' or 'N' = loop continues

    Is that what you meant?
  4. Re: while loop loops foreve even with the right inputs.

    Whoa! Slow down. Make sense. Communicate clearly. It's not clear you understand the requirement, and if you don't understand it or can't communicate it clearly, then we can't help you.
Results 1 to 4 of 4