3v4l.org

run code in 300+ PHP versions simultaneously
<?php // Fill up array with names $a[]="Anna"; $a[]="Brittany"; $a[]="Cinderella"; $a[]="Diana"; $a[]="Eva"; $a[]="Fiona"; $a[]="Gunda"; $a[]="Hege"; $a[]="Inga"; $a[]="Johanna"; $a[]="Kitty"; $a[]="Linda"; $a[]="Nina"; $a[]="Ophelia"; $a[]="Petunia"; $a[]="Amanda"; $a[]="Raquel"; $a[]="Cindy"; $a[]="Doris"; $a[]="Eve"; $a[]="Evita"; $a[]="Sunniva"; $a[]="Tove"; $a[]="Unni"; $a[]="Violet"; $a[]="Liza"; $a[]="Elizabeth"; $a[]="Ellen"; $a[]="Wenche"; $a[]="Vicky"; //get the q parameter from URL $q="E{$a[25]}"; //lookup all hints from array if length of q>0 if (strlen($q) > 0) { $hint=""; for($i=0; $i<count($a); $i++) { if (strtolower($q)==strtolower(substr($a[$i],0,strlen($q)))) { if ($hint=="") { $hint=$a[$i]; } else { $hint=$hint." , ".$a[$i]; } } } } // Set output to "no suggestion" if no hint were found // or to the correct values if ($hint == "") { $response="no suggestion"; } else { $response=$hint; } //output the response echo $response; ?>

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)
8.3.60.0090.01116.50
8.3.50.0080.00722.16
8.3.40.0090.00618.71
8.3.30.0100.00319.21
8.3.20.0030.00520.22
8.3.10.0080.00023.71
8.3.00.0000.01020.77
8.2.180.0100.00518.66
8.2.170.0110.00322.96
8.2.160.0100.00320.57
8.2.150.0040.00424.18
8.2.140.0030.00624.66
8.2.130.0040.00426.16
8.2.120.0000.00822.09
8.2.110.0060.00322.25
8.2.100.0070.00417.97
8.2.90.0040.00419.25
8.2.80.0080.00017.97
8.2.70.0000.00917.63
8.2.60.0050.00318.05
8.2.50.0040.00418.07
8.2.40.0040.00418.16
8.2.30.0070.00018.13
8.2.20.0040.00417.63
8.2.10.0000.00717.76
8.2.00.0000.00817.68
8.1.280.0180.00425.92
8.1.270.0080.00023.92
8.1.260.0060.00326.35
8.1.250.0070.00028.09
8.1.240.0080.00023.96
8.1.230.0160.00019.10
8.1.220.0040.00417.74
8.1.210.0030.00518.77
8.1.200.0030.00617.23
8.1.190.0040.00417.41
8.1.180.0060.00318.10
8.1.170.0040.00418.59
8.1.160.0000.00922.02
8.1.150.0070.00018.65
8.1.140.0050.00317.38
8.1.130.0070.00017.84
8.1.120.0040.00417.42
8.1.110.0040.00417.35
8.1.100.0050.00517.36
8.1.90.0040.00417.44
8.1.80.0000.00717.53
8.1.70.0080.00017.47
8.1.60.0050.00317.62
8.1.50.0060.00317.43
8.1.40.0040.00417.54
8.1.30.0000.00817.51
8.1.20.0040.00417.57
8.1.10.0030.00517.46
8.1.00.0070.00317.53
8.0.300.0080.00018.77
8.0.290.0070.00017.04
8.0.280.0070.00018.46
8.0.270.0030.00317.27
8.0.260.0000.00616.75
8.0.250.0040.00416.96
8.0.240.0000.00816.84
8.0.230.0050.00316.86
8.0.220.0000.00716.96
8.0.210.0080.00016.89
8.0.200.0050.00216.93
8.0.190.0060.00316.99
8.0.180.0030.00616.97
8.0.170.0040.00416.83
8.0.160.0000.00716.84
8.0.150.0030.00316.83
8.0.140.0000.00816.87
8.0.130.0030.00313.29
8.0.120.0020.00516.87
8.0.110.0000.00716.88
8.0.100.0060.00316.90
8.0.90.0040.00416.94
8.0.80.0040.01116.96
8.0.70.0040.00416.79
8.0.60.0030.00516.77
8.0.50.0040.00416.89
8.0.30.0080.01017.18
8.0.20.0090.01117.40
8.0.10.0000.00816.97
8.0.00.0160.00216.68
7.4.330.0000.00615.09
7.4.320.0000.00716.52
7.4.300.0030.00316.61
7.4.290.0030.00316.50
7.4.280.0030.00316.41
7.4.270.0070.00016.62
7.4.260.0020.00516.60
7.4.250.0050.00316.48
7.4.240.0030.00316.59
7.4.230.0000.00716.31
7.4.220.0070.01116.55
7.4.210.0050.01116.55
7.4.200.0050.00316.35
7.4.190.0030.00516.77
7.4.160.0060.00916.51
7.4.150.0030.01617.40
7.4.140.0120.00717.86
7.4.130.0100.00616.51
7.4.120.0030.01316.60
7.4.110.0130.01016.46
7.4.100.0090.00916.54
7.4.90.0140.00316.64
7.4.80.0110.00619.39
7.4.70.0040.01216.54
7.4.60.0090.00916.48
7.4.50.0030.00516.40
7.4.40.0070.01322.77
7.4.30.0110.00516.35
7.4.00.0070.00714.70
7.3.330.0000.00513.14
7.3.320.0050.00013.20
7.3.310.0030.00316.41
7.3.300.0030.00316.37
7.3.290.0100.01016.34
7.3.280.0060.01016.34
7.3.270.0150.00317.40
7.3.260.0100.01316.54
7.3.250.0110.00616.47
7.3.240.0060.00916.29
7.3.230.0090.00916.52
7.3.210.0110.00716.62
7.3.200.0090.01219.39
7.3.190.0170.00616.46
7.3.180.0090.00616.36
7.3.170.0120.00916.48
7.3.160.0060.00916.50
7.3.120.0070.00714.86
7.2.330.0060.01116.80
7.2.320.0100.01316.56
7.2.310.0110.00516.71
7.2.300.0100.00616.72
7.2.290.0100.00616.78
7.2.00.0030.01019.04
7.1.200.0070.00315.93
7.1.100.0030.00617.98
7.1.70.0000.01017.24
7.1.60.0100.01419.29
7.1.50.0130.01317.12
7.1.00.0000.08022.45
7.0.200.0030.00616.83
7.0.140.0000.07722.10
7.0.60.0070.06320.02
7.0.50.0170.06717.83
7.0.40.0100.06720.40
7.0.30.0330.08020.24
7.0.20.0300.04020.18
7.0.10.0300.06020.08
7.0.00.0070.08720.04
5.6.280.0030.07321.14
5.6.210.0070.07020.61
5.6.200.0100.04318.12
5.6.190.0130.07320.45
5.6.180.0070.08020.36
5.6.170.0230.05320.45
5.6.160.0030.04320.50
5.6.150.0100.07018.07
5.6.140.0170.02718.14
5.6.130.0170.07318.21
5.6.120.0170.07321.10
5.6.110.0070.07021.00
5.6.100.0130.07721.11
5.6.90.0170.06321.02
5.6.80.0070.07720.54
5.5.350.0070.07720.39
5.5.340.0000.04318.01
5.5.330.0000.04320.15
5.5.320.0070.05320.29
5.5.310.0130.04320.27
5.5.300.0100.08317.95
5.5.290.0070.07318.00
5.5.280.0100.07720.77
5.5.270.0070.04320.94
5.5.260.0070.05320.80
5.5.250.0030.07320.79
5.5.240.0070.03320.07
5.4.450.0970.04019.41
5.4.440.0730.06319.37
5.4.430.0070.06019.52
5.4.420.0630.06019.54
5.4.410.0530.04719.37
5.4.400.0770.05319.22
5.4.390.0830.05318.89
5.4.380.0230.07318.57
5.4.370.0170.06018.78
5.4.360.0200.05718.64
5.4.350.0200.07318.72
5.4.340.0330.06318.76
5.4.320.0050.03812.46
5.4.310.0030.04612.46
5.4.300.0030.04012.47
5.4.290.0100.03712.46
5.4.280.0100.03412.36
5.4.270.0070.04212.36
5.4.260.0060.04512.36
5.4.250.0050.03812.36
5.4.240.0090.04012.36
5.4.230.0070.03712.35
5.4.220.0050.03912.35
5.4.210.0070.04012.36
5.4.200.0110.03712.36
5.4.190.0130.04612.35
5.4.180.0170.04412.35
5.4.170.0310.09112.36
5.4.160.0380.08212.35
5.4.150.0130.04512.35
5.4.140.0150.04212.03
5.4.130.0170.04112.02
5.4.120.0300.08711.98
5.4.110.0120.04611.98
5.4.100.0140.04811.97
5.4.90.0160.04111.97
5.4.80.0170.04011.97
5.4.70.0220.03511.97
5.4.60.0170.04211.97
5.4.50.0140.04411.97
5.4.40.0180.04111.96
5.4.30.0170.04211.96
5.4.20.0150.04111.96
5.4.10.0170.04311.96
5.4.00.0120.04411.45
5.3.290.0120.04112.80
5.3.280.0070.05012.71
5.3.270.0230.06712.72
5.3.260.0180.04312.72
5.3.250.0160.04612.72
5.3.240.0150.04412.72
5.3.230.0110.05112.71
5.3.220.0180.04412.68
5.3.210.0150.04512.68
5.3.200.0120.04812.68
5.3.190.0200.04112.68
5.3.180.0340.08512.67
5.3.170.0190.04212.66
5.3.160.0160.04512.68
5.3.150.0180.04412.67
5.3.140.0150.04712.66
5.3.130.0180.04512.65
5.3.120.0150.04412.66
5.3.110.0170.04312.66
5.3.100.0190.04112.11
5.3.90.0160.04312.09
5.3.80.0120.04812.07
5.3.70.0170.04212.07
5.3.60.0150.04412.07
5.3.50.0420.07712.01
5.3.40.0140.04412.01
5.3.30.0160.04011.97
5.3.20.0160.04111.75
5.3.10.0150.04311.71
5.3.00.0160.04511.70
5.2.170.0120.0379.20
5.2.160.0130.0359.21
5.2.150.0130.0379.21
5.2.140.0140.0349.20
5.2.130.0130.0349.16
5.2.120.0120.0359.16
5.2.110.0120.0359.16
5.2.100.0120.0369.16
5.2.90.0140.0319.16
5.2.80.0120.0349.15
5.2.70.0130.0349.15
5.2.60.0100.0369.11
5.2.50.0170.0299.07
5.2.40.0130.0349.05
5.2.30.0120.0339.03
5.2.20.0130.0349.02
5.2.10.0090.0388.95
5.2.00.0110.0388.79
5.1.60.0150.0568.08
5.1.50.0160.0278.08
5.1.40.0150.0288.07
5.1.30.0120.0328.41
5.1.20.0110.0318.44
5.1.10.0150.0278.16
5.1.00.0110.0308.16
5.0.50.0080.0256.65
5.0.40.0120.0206.51
5.0.30.0090.0356.32
5.0.20.0110.0216.30
5.0.10.0090.0226.27
5.0.00.0110.0356.27
4.4.90.0080.0184.77
4.4.80.0070.0184.75
4.4.70.0210.0674.75
4.4.60.0080.0184.75
4.4.50.0090.0174.77
4.4.40.0090.0284.71
4.4.30.0070.0234.76
4.4.20.0140.0204.84
4.4.10.0090.0194.85
4.4.00.0230.0764.76
4.3.110.0060.0204.66
4.3.100.0090.0184.66
4.3.90.0090.0184.63
4.3.80.0100.0314.58
4.3.70.0160.0704.63
4.3.60.0080.0214.63
4.3.50.0080.0194.63
4.3.40.0100.0294.54
4.3.30.0040.0203.32
4.3.20.0190.0683.30
4.3.10.0050.0203.26
4.3.00.0070.01315.63

preferences:
46.37 ms | 401 KiB | 5 Q