3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* * Get Full Filter Name from Abbreviation */ function getFilterName($filterAbbreviation) { return "Restaurant"; /*$filters = array( "R" => "Restuarant", "B" => "Bar", "S" => "Store", "L" => "Lodging", "Q" => "Recreation", "G" => "Gas Station", "E" => "Entertainment", "C" => "Club" ); return $filters[$filterAbbreviation];*/ } function parseFilterString($filterString) { $returnVal = ""; $filterLetters = str_split($filterString, 1);    for($x = 0; $x < strlen($filterString); $x++) {        $returnVal .= "(type <=> '" . getFilterName($filterLetters[$x]) . "') OR ";    }     if (strlen($returnVal) > 0) $returnVal =  substr($returnVal,0,-4); //remove final " OR " from filterstring else $returnVal = "type = 'VOID'"; if everything is filtered, make sure to set type to something not available*/ return $returnVal; } ?>

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)
5.4.90.0140.04412.01
5.4.80.0150.04012.02
5.4.70.0150.04012.01
5.4.60.0130.04312.01
5.4.50.0130.04112.01
5.4.40.0150.05012.00
5.4.30.0140.04211.99
5.4.20.0100.04711.99
5.4.10.0120.04211.99
5.4.00.0150.04011.49
5.3.190.0150.04412.68
5.3.180.0160.04112.67
5.3.170.0150.04412.67
5.3.160.0120.04412.67
5.3.150.0150.04312.67
5.3.140.0180.04312.66
5.3.130.0140.04512.66
5.3.120.0190.05112.66
5.3.110.0140.04512.66
5.3.100.0120.04612.12
5.3.90.0170.05112.10
5.3.80.0170.05212.09
5.3.70.0160.04212.09
5.3.60.0180.04312.08
5.3.50.0130.04312.02
5.3.40.0140.04312.02
5.3.30.0160.03811.99
5.3.20.0160.04011.77
5.3.10.0200.06011.73
5.3.00.0140.04611.71

preferences:
134.52 ms | 1394 KiB | 7 Q