Loose Comparison Operators : Comparison Operators « Operator « PHP






Loose Comparison Operators

 
Example         Name                            Description 
$a == $b        Equal to                        True if $ais equal to $b 
$a != $b        Not equal to                    True if $ais not equal to $b 
$a < $b         Less than                       True if $ais less than $b 
$a > $b         Greater than                    True if $ais greater than $b 
$a <= $b        Less than or equal to           True if $ais less than or equal to $b 
$a >= $b        Greater than or equal to        True if $a is greater than or equal to $b 
$a === $b       Equal to                        True if $ais equal to $b and they are of the same type
$a !== $b       Not equal to                    True if $ais not equal to $bor they are not of the same type
  
  








Related examples in the same category

1.Comparison Operators
2.Comparing numbers and strings
3.Using Comparison Operators in if Statements
4.The Ternary Operator
5.The equality operator
6.These values are compared using dictionary order
7.These values are compared using numeric order
8.Equality Operators summary table
9.Equality Operators in action