3v4l.org

run code in 300+ PHP versions simultaneously
<?php $bool = false; $int = 0; echo 'is ', var_export($bool, true), ' == ', var_export($int, true), '? ', var_export($bool == $int), "\n"; $str = (string)$bool; echo 'is ', var_export($str, true), ' empty? ', var_export(empty($str)), "\n"; $int = (int)$str; echo 'is ', var_export($int, true), ' empty? ', var_export(empty($int)), "\n";

preferences:
36.95 ms | 402 KiB | 5 Q