note 44968 deleted from types.comparisons by tomsommer
| From: | tomsommer@php.net | Date: | Sat, 21 Aug 2004 15:28:55 +0000 |
| Subject: | note 44968 deleted from types.comparisons by tomsommer | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-75061@lists.php.net to get a copy of this message | ||
Note Submitter: rabbott at calstatela dot edu
----
So it looks like in comparison of two elements if either is a number, the other is cast to a number.
["x" == 0.0 is true]
If both are strings that can be cast to numbers they will be. ["005" == "5.00"
is true]
If only one can be cast to a number, neither will be. ["x" == "0" is false]