Need a little help with how to do loops in this case...

Okay, hi , I have this program where I'm trying to print out a loop where
x can't be less than 0 or greater than 10 and y can't be less than 0 or greater than 10.

I don't believe that this can be used:
while (x !< 0);
and such... so How would I do something similar to this while using a loop?

Thank you !
I don't know if you have x and y on different loops or in the same loop. Checking for ranges would look something like this for either:

1
2
// if x is greater than or equal to 0 and if x is less than or equal to 10 then we succeed and loop again.
while ( ( x >= 0) && (x <= 10))


if I needed to make sure both were in range
 
while( ( (x >= 0) && (x <= 10) )  || ( (y >=0) && (y <=10) ) )

Topic archived. No new replies allowed.