I was reading PHP's Array man and I saw this:
<?php
// fill an array with all items from a directory
$handle = opendir('.');
while (false !== ($file = readdir($handle))) {
$files[] = $file;
}
closedir($handle);
?>
In the readdir man page, it says "Correctly way of looping".
I'd like to know if there's a difference between X !== false
and false !== X
. Thanks!