3v4l.org

run code in 300+ PHP versions simultaneously
<?php if (!isset($_SESSION)) { header("Location:input.php"); } else { $greeting = "Welcome " .$_SESSION["username"]. ", let's string your strings " .$_SESSION["s1"]. " and " .$_SESSION["s2"]. "!"; if (!isset($_GET["conxy"]) { $conxvar = ""; // function to conx+y with GET and append parameter to URL } else { $conxvar = "The strings x+y have been concatenated: ". $_SESSION['s1'].$_SESSION['s2']; echo $conxvar; } if (!isset($_GET["conyx"]) { $conyvar = ""; // function to conx+y with GET and append parameter to URL } else { $conyvar = "The strings y+x have been concatenated: ". $_SESSION['s2'].$_SESSION['s1']; echo $conyvar; } if (!isset($_GET["conyx"])) { $subvar = ""; // function to check substring with GET and append parameter to URL } else { $compareX = strpos($_SESSION['s2'], $_SESSION['s1']); $compareY = strpos($_SESSION['s1'], $_SESSION['s2']); if ($compareX !== false) { $subvar = "String ".$_SESSION['s1']. " is a substring of " .$_SESSION['s2']; } else { $subvar = "String ".$_SESSION['s1']. " is NOT a substring of " .$_SESSION['s2']; } if ($compareY !== false) { $subvar += " and string ".$_SESSION['s2']. " is a substring of " .$_SESSION['s1']; } else { $subvar += " and string ".$_SESSION['s2']. " is NOT a substring of " .$_SESSION['s1']; } echo $subvar; } } ?>

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.280.0080.04012.39
5.4.270.0070.04312.39
5.4.260.0080.04012.39
5.4.250.0060.05212.39
5.4.240.0090.05112.39
5.4.230.0070.04312.39
5.4.220.0060.03812.39
5.4.210.0060.04112.39
5.4.200.0100.05312.38
5.4.190.0070.04212.38
5.4.180.0090.06312.38
5.4.170.0100.04712.39
5.4.160.0090.04112.39
5.4.150.0070.03812.38
5.4.140.0090.05112.07
5.4.130.0070.03712.05
5.4.120.0100.03412.02
5.4.110.0060.03812.01
5.4.100.0100.04012.01
5.4.90.0090.04312.01
5.4.80.0080.04612.01
5.4.70.0090.05012.01
5.4.60.0080.05212.01
5.4.50.0100.03412.00
5.4.40.0080.03411.99
5.4.30.0070.04011.99
5.4.20.0070.04811.99
5.4.10.0070.04011.99
5.4.00.0090.03911.48
5.3.280.0090.04212.71
5.3.270.0130.05912.72
5.3.260.0070.04812.72
5.3.250.0080.03912.72
5.3.240.0080.04112.72
5.3.230.0060.04412.71
5.3.220.0090.04812.68
5.3.210.0060.04412.68
5.3.200.0090.04012.68
5.3.190.0090.04112.68
5.3.180.0080.04312.67
5.3.170.0070.03912.67
5.3.160.0080.04812.67
5.3.150.0100.04612.67
5.3.140.0090.04512.66
5.3.130.0100.04512.66
5.3.120.0110.04612.66
5.3.110.0060.04812.66
5.3.100.0110.04412.12
5.3.90.0080.04112.08
5.3.80.0070.04412.07
5.3.70.0070.04012.07
5.3.60.0060.04212.06
5.3.50.0060.05112.00
5.3.40.0080.04212.00
5.3.30.0070.04711.95
5.3.20.0070.04111.73
5.3.10.0070.04411.70
5.3.00.0090.04511.69

preferences:
144.3 ms | 1394 KiB | 7 Q