Difference between revisions of "Operator Reference"
Jump to navigation
Jump to search
→Logical Operators
imported>Mr Wallet |
imported>Black RL |
||
Line 105: | Line 105: | ||
*The NOT operator (!) will be true if its single expression (to the right of the operator) is false, and false if it is true. | *The NOT operator (!) will be true if its single expression (to the right of the operator) is false, and false if it is true. | ||
*The OR operator (||) will be true if one of the expressions to its left and right are true, and will short-circuit if the left expression is true (it will not evaluate the right expression at all). | *The OR operator (||) will be true if one of the expressions to its left and right are true, and will short-circuit if the left expression is true (it will not evaluate the right expression at all). | ||
*Note that If A == (B || C || D) is a common mistake, it should be If A == B || A == C || A == D, read more [http://forums.bethsoft.com/topic/1460024-operator-or-question/ here] | |||
*The AND operator (&&) will be true if both of the expressions to its left and right are true, and will short-circuit if the left expression is false (it will not evaluate the right expression at all). | *The AND operator (&&) will be true if both of the expressions to its left and right are true, and will short-circuit if the left expression is false (it will not evaluate the right expression at all). | ||