3v4l.org

run code in 300+ PHP versions simultaneously
<?php $regex = '/[.{8,60}]/'; $tests = [ 'abc', 'abc123', 'abc123#', 'abc123#!', 'abc123#!a1', ]; while ($test = array_shift($tests)) { var_dump(preg_match($regex, $test)); } echo PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL; echo bin2hex(random_bytes(10)).PHP_EOL;

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
7.2.00.0080.00820.02

preferences:
32.12 ms | 403 KiB | 5 Q