I was reading the c++ tutorials when I got to the Boolean operators. I kinda got the idea of AND, OR, and NOT (&&, ||, and !).
Well, to tell the truth, I barely got it at all...
Worse is that I dont even know how to use them. The sample code looks like this:
How do I put that into a program? It said it would be simple, but I need help...Code:A. !( 1 || 0 ) ANSWER: 0 B. !( 1 || 1 && 0 ) ANSWER: 0 (AND is evaluated before OR) C. !( ( 1 || 0 ) && 0 ) ANSWER: 1 (Parenthesis are useful)
Thanks!



LinkBack URL
About LinkBacks


