Originally posted by Larry Jones:
Thank you everyone for your responses. I understand what is going on in the code now, but I would like to ask one more question: Can someone give me a simple example of a && operator being evaluated before the || operator? That is, in what situation does the && operator show it has higher precedence? I've tried many little programs, but the results seem to indicate that || and && have the same precedence and are evaluated from left to right.
This will print "true" because && has precedence over ||. a && b evaluates to false, and then the false || c resolves to true, so true is printed.