3v4l.org

run code in 300+ PHP versions simultaneously
<?php $tests = array( "42", 1337, "1e4", "not numeric", 9.1, '234ffffdsf' ); foreach ($tests as $element) { if (is_numeric($element)) { echo "'{$element}' - число", PHP_EOL; } else { echo "'{$element}' - НЕ число", PHP_EOL; } }

preferences:
40.37 ms | 402 KiB | 5 Q