Boolean Expressions, If Statements and Loops

Boolean Expressions

 
A boolean expression is evaluated by using certain operators to come to a true or false answer. The operators are:
 
== – Returns true if the values on either side are equal
 
!= – Returns true if the values on either side are not equal
 
< – Returns true if the value on the left is less than the value on the right
 
<= – Returns true if the value on the left is less than or equal to the value on the right
 
> – Returns true if the value on the left is greater than the value on the right
 
>= – Returns true if the value on the left is greater than or equal to the value on the right
 
&& – (And) Returns true if both values are true.
 
|| – (Or) Returns true if either value is true
 

Read moreBoolean Expressions, If Statements and Loops

Please follow and like us:
Facebook
Facebook
Google+
Google+
http://aiclarke.com/tag/else-if">
YouTube
LinkedIn
RSS