//EXCUTE THIS UNTIL ONE OF THE METHODS RETURN FALSE
The above says, "keep looping as long as m1() and m2() both return true." That's what "while" means in English and in Java. You seem to have been treating "while" as if it meant "until."
Note that when using &&, if m1() returns false, it won't bother evaluating m2(), wince it can't affect the outcome of the if condition. If you want m2() to execute even if m1() returns false, use & instead of &&.
amr talaat wrote:I WANT TO DO THIS
Amr, please KeepItDown (←click). Posting in all caps is akin to shouting, and it doesn't make pleasant reading.
I think Jeff has basically answered your question, but I'd also suggest that you try to avoid "negative" (!) logic if you can.
if (true) is generally a lot easier to follow than
if (!false) especially if the expression is a compound one.
"Leadership is nature's way of removing morons from the productive flow" - Dogbert
Articles by Winston can be found here