note 75503 deleted from function.is-numeric by cmb
| From: | cmb@php.net | Date: | Sun, 23 Jun 2019 10:35:12 +0000 |
| Subject: | note 75503 deleted from function.is-numeric by cmb | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-211350@lists.php.net to get a copy of this message | ||
Note Submitter: Carlos Madeira
----
If I may, i think there is a simpler way to determine if a number is odd or even:
if( $number & 1 ) //Just check the last bit!
echo 'It's odd!';
else
echo 'It's even!';