Showing posts with label learn c sharp Gaming Chapter 5. Show all posts
Showing posts with label learn c sharp Gaming Chapter 5. Show all posts

Monday, March 28, 2011

learn c sharp Gaming Chapter 5


Short-Circuit Evaluation
Let me go off on a tangent here and go over a topic that is fairly important when evaluating
conditional statements.
All C-based languages support something called short-circuit evaluation. This is a very
helpful performance tool, but it can cause some problems for you if you want to perform
some fancy code tricks.
If you know your binary math rules, then you know that with an and statement, if either
one of the operands is false, then the entire thing is false. Table 2.7 lists the logical and and
logical or result tables.
Look at the table, specifically the two lines where x is false. For the operation “x and y,” it
doesn’t matter what y is because the result is always going to be false. Likewise, if you look
at the first two lines, you’ll notice that whenever x is true, the operation “x or y” is true,
no matter what y is.

AngularJS Basics - Part 1

                                                                  AngularJS What is AngularJS ·          Framework by googl...