Relational Operators in action : Logical Operators « Operator « PHP






Relational Operators in action

<html>
<head>
   <title>Relational Operators</title>
</head>
<body>
     <?php
        print("(5 < 5) is "  . ((5 < 5) ? "True" : "False") . "<br />");
        print("(5 <= 5) is "  . ((5 <= 5) ? "True" : "False") . "<br />");
        print("(5 > 5) is "  . ((5 > 5) ? "True" : "False") . "<br />");
        print("(5 >= 5) is "  . ((5 >= 5) ? "True" : "False") . "<br />");
     ?>
</body>
</html>
           
       








Related examples in the same category

1.Logical Operators in Order of Precedence
2.Use the boolean compare operators
3.Greater than
4.Less than
5.Greate and equal
6.Less than and equal
7.Not equal: !=
8.Logical Operators
9.Logic Operators in PHP
10.Or operator
11.Leap Year Determination
12.Negation operator
13.The not-equals operator
14.Relational Operators summary table