1, for the array
$a =array (1,2,3,6);
$b =array (1,2,3,6,8);
echo "\ n";
Var_dump ($a > $b);
Var_dump ($a = = $b);
Var_dump ($a < $b);
Results:
Boolean false
Boolean false
Boolean true
PS: Smaller arrays with fewer members
$a =array (1,2,3,6,9);
$b =array (1,2,3,6,8);
echo "\ n";
Var_dump ($a > $b);
Var_dump ($a = = $b);
Var_dump ($a < $b);
Boolean true
Boolean false
Boolean false
PS: A comparison of the values
$a =array (1,2,3,6, ' B ' =>3);
$b =array (1,2,3,6,8);
echo "\ n";
Var_dump ($a > $b);
Var_dump ($a = = $b);
Var_dump ($a < $b);
Boolean false
Boolean false
Boolean false
PS: If the key in operand 1 does not exist in operand 2, the array cannot be compared and returns false.
2. for bool or null and other types comparison
Var_dump ((BOOL) (NULL)), False when//boolean False//null is converted to bool;
Null and other types are converted to bool, then compared, and false < TRUE