3v4l.org

run code in 300+ PHP versions simultaneously
<?php $list = array( "Data" => "9", "Data Structure" => "10", "Database" => "11", "Creativity" => "12", "Forest" => "13", "Al Pacino" => "14", "Humans" => "15", "Technology" => "16" ); $post = array ('Database', 'Law', 'Tech', 'Creative'); $all_key_values = $all_keys = array(); foreach ($post as $keyword) { foreach ($list as $word=>$num) { $sim_chars = similar_text($keyword, $word, $percent); if ($percent > 80) { $all_key_values[] = $num; $all_keys[] = $word; } elseif ($sim_chars/strlen($keyword) > .8 || $sim_chars/strlen($word) > .8) { $all_key_values[] = $num; $all_keys[] = $word; } elseif (strpos($keyword, $word) !== false || strpos($word, $keyword)) { $sll_key_values[] = $num; $all_keys[] = $word; } } } print_r(implode(',', $all_key_values)); echo "\n"; print_r(implode(',', $all_keys));

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.40.0100.01018.70
8.3.30.0150.00019.09
8.3.20.0050.00320.35
8.3.10.0040.00423.61
8.3.00.0060.00319.38
8.2.170.0110.00422.96
8.2.160.0000.01420.41
8.2.150.0000.00824.18
8.2.140.0080.00024.66
8.2.130.0040.00426.16
8.2.120.0070.00022.25
8.2.110.0060.00322.25
8.2.100.0120.00018.03
8.2.90.0030.00619.18
8.2.80.0060.00318.05
8.2.70.0080.00317.63
8.2.60.0000.00718.05
8.2.50.0040.00418.07
8.2.40.0000.00819.71
8.2.30.0060.00319.80
8.2.20.0080.00017.67
8.2.10.0040.00419.91
8.2.00.0030.00617.82
8.1.270.0000.00923.79
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0060.00323.96
8.1.230.0080.00319.01
8.1.220.0080.00017.79
8.1.210.0030.00618.77
8.1.200.0000.00917.35
8.1.190.0000.00817.22
8.1.180.0030.00719.01
8.1.170.0060.00318.46
8.1.160.0000.00821.95
8.1.150.0040.00418.65
8.1.140.0040.00417.38
8.1.130.0000.00717.88
8.1.120.0040.00417.41
8.1.110.0030.00517.54
8.1.100.0080.00017.54
8.1.90.0000.00717.48
8.1.80.0030.00417.47
8.1.70.0030.00317.38
8.1.60.0050.00217.48
8.1.50.0030.00517.57
8.1.40.0040.00417.55
8.1.30.0040.00417.63
8.1.20.0050.00217.57
8.1.10.0000.01017.52
8.1.00.0000.00817.35
8.0.300.0000.00718.77
8.0.290.0040.00416.93
8.0.280.0000.00718.46
8.0.270.0000.00717.31
8.0.260.0000.00717.14
8.0.250.0030.00317.02
8.0.240.0000.00816.84
8.0.230.0000.00717.04
8.0.220.0070.00016.89
8.0.210.0000.00716.95
8.0.200.0040.00417.03
8.0.190.0040.00416.80
8.0.180.0000.00716.93
8.0.170.0030.00616.79
8.0.160.0040.00416.78
8.0.150.0040.00416.71
8.0.140.0040.00416.79
8.0.130.0060.00013.39
8.0.120.0040.00416.77
8.0.110.0070.00016.82
8.0.100.0000.00716.97
8.0.90.0000.00816.81
8.0.80.0110.00716.81
8.0.70.0030.00316.74
8.0.60.0040.00417.02
8.0.50.0030.00516.86
8.0.30.0060.01217.14
8.0.20.0080.01217.40
8.0.10.0060.00316.89
8.0.00.0100.00816.71
7.4.330.0030.00315.00
7.4.320.0060.00016.66
7.4.300.0030.00316.53
7.4.290.0070.00016.62
7.4.280.0030.00316.41
7.4.270.0000.00716.61
7.4.260.0080.00016.59
7.4.250.0050.00316.40
7.4.240.0070.00016.50
7.4.230.0030.00316.50
7.4.220.0030.02116.44
7.4.210.0080.00716.56
7.4.200.0000.00716.52
7.4.190.0000.00716.60
7.4.160.0100.00616.55
7.4.150.0150.00417.40
7.4.140.0080.00817.86
7.4.130.0050.01216.49
7.4.120.0100.00816.65
7.4.110.0110.00716.65
7.4.100.0090.00916.36
7.4.90.0030.01516.61
7.4.80.0060.01219.39
7.4.70.0100.01316.45
7.4.60.0090.00616.64
7.4.50.0030.00316.43
7.4.40.0100.01016.61
7.4.30.0100.00616.55
7.4.00.0100.00814.98
7.3.330.0030.00313.27
7.3.320.0000.00513.33
7.3.310.0040.00416.34
7.3.300.0000.00616.29
7.3.290.0090.00616.31
7.3.280.0100.01016.33
7.3.270.0070.01017.40
7.3.260.0150.00616.27
7.3.250.0060.01516.36
7.3.240.0140.00316.54
7.3.230.0030.02016.44
7.3.210.0100.00816.57
7.3.200.0090.01219.39
7.3.190.0120.00616.58
7.3.180.0070.00916.52
7.3.170.0130.00316.60
7.3.160.0080.00816.29
7.3.120.0030.01114.82
7.3.110.0090.00614.89
7.3.100.0070.01014.59
7.3.90.0130.00315.05
7.3.80.0120.00314.78
7.3.70.0090.00614.95
7.3.60.0100.00715.01
7.3.50.0030.01414.90
7.3.40.0100.00315.01
7.3.30.0000.01514.73
7.3.20.0150.00016.57
7.3.10.0110.00416.68
7.3.00.0070.00716.84
7.2.330.0040.01416.62
7.2.320.0070.01016.76
7.2.310.0110.01116.93
7.2.300.0070.01716.52
7.2.290.0070.01416.71
7.2.250.0090.00614.96
7.2.240.0030.01515.36
7.2.230.0070.01014.91
7.2.220.0060.00314.81
7.2.210.0090.00615.06
7.2.200.0030.01615.02
7.2.190.0090.00615.18
7.2.180.0060.01014.70
7.2.170.0060.00615.16
7.2.00.0070.00319.57
7.1.330.0040.00915.82
7.1.320.0090.00615.54
7.1.310.0060.00315.80
7.1.300.0030.00915.70
7.1.290.0060.00815.89
7.1.280.0030.00715.94
7.1.270.0000.01415.70
7.1.260.0140.00315.49
7.1.100.0030.00718.04
7.1.70.0120.00617.13
7.1.60.0060.01019.46
7.1.50.0040.01517.03
7.1.00.0070.07322.44
7.0.200.0230.00814.60
7.0.140.0000.07322.04
7.0.100.0170.03719.93
7.0.90.0130.05019.89
7.0.80.0100.04020.09
7.0.70.0100.06319.83
7.0.60.0130.06019.84
7.0.50.0000.04320.27
7.0.40.0070.03720.07
7.0.30.0100.04019.96
7.0.20.0030.04719.95
7.0.10.0030.04719.98
7.0.00.0030.04320.07
5.6.280.0000.07720.83
5.6.250.0100.03020.55
5.6.240.0030.05720.53
5.6.230.0000.04720.52
5.6.220.0130.06320.66
5.6.210.0070.03720.62
5.6.200.0000.04721.00
5.6.190.0070.05321.05
5.6.180.0030.04721.01
5.6.170.0100.04020.97
5.6.160.0070.04321.14
5.6.150.0070.05720.98
5.6.140.0070.04020.90
5.6.130.0100.04021.14
5.6.120.0030.07721.01
5.6.110.0070.03720.92
5.6.100.0000.06021.09
5.6.90.0130.07721.08
5.6.80.0130.07320.30
5.6.70.0070.08020.40
5.6.60.0070.05320.34
5.6.50.0130.07020.38
5.6.40.0130.07020.37
5.6.30.0100.07320.50
5.6.20.0030.08720.33
5.6.10.0100.07320.26
5.6.00.0070.07720.32
5.5.380.0000.06020.38
5.5.370.0030.06720.36
5.5.360.0100.07020.34
5.5.350.0070.07320.43
5.5.340.0000.04320.89
5.5.330.0070.04020.88
5.5.320.0030.04320.84
5.5.310.0100.03720.88
5.5.300.0100.05020.73
5.5.290.0070.04020.85
5.5.280.0000.05720.74
5.5.270.0030.04020.55
5.5.260.0000.04320.86
5.5.250.0000.08020.58
5.5.240.0100.08020.28
5.5.230.0100.08020.14
5.5.220.0100.04320.26
5.5.210.0130.07320.22
5.5.200.0130.07020.24
5.5.190.0030.08020.18
5.5.180.0130.07319.96
5.5.160.0130.07319.91
5.5.150.0100.07019.95
5.5.140.0000.05020.22
5.5.130.0000.08320.16
5.5.120.0030.08719.92
5.5.110.0070.08720.05
5.5.100.0070.04320.14
5.5.90.0130.07320.06
5.5.80.0100.04019.97
5.5.70.0200.06020.05
5.5.60.0130.03720.00
5.5.50.0100.08020.03
5.5.40.0070.07320.06
5.5.30.0100.07320.12
5.5.20.0200.07020.08
5.5.10.0200.06320.03
5.5.00.0100.08019.94
5.4.450.0000.05019.40
5.4.440.0070.04019.14
5.4.430.0070.05319.29
5.4.420.0070.05319.36
5.4.410.0070.07719.24
5.4.400.0130.07318.95
5.4.390.0070.07719.03
5.4.380.0130.06318.95
5.4.370.0170.06318.98
5.4.360.0070.07318.98
5.4.350.0130.07018.97
5.4.340.0170.07019.12
5.4.320.0170.06719.14
5.4.310.0070.07318.96
5.4.300.0100.07018.81
5.4.290.0070.05719.03
5.4.280.0030.07319.04
5.4.270.0100.07318.89
5.4.260.0000.08318.81
5.4.250.0100.07719.23
5.4.240.0130.07018.89
5.4.230.0000.08319.13
5.4.220.0130.06018.97
5.4.210.0130.05018.96
5.4.200.0070.07319.02
5.4.190.0100.07319.05
5.4.180.0100.07718.93
5.4.170.0100.07718.80
5.4.160.0170.06019.21
5.4.150.0070.07719.01
5.4.140.0030.08016.29
5.4.130.0130.06316.30
5.4.120.0100.06316.13
5.4.110.0030.07316.39
5.4.100.0130.07016.42
5.4.90.0030.07316.22
5.4.80.0070.07016.20
5.4.70.0130.06016.30
5.4.60.0070.07016.40
5.4.50.0070.05316.38
5.4.40.0000.05016.45
5.4.30.0000.07716.38
5.4.20.0070.05316.28
5.4.10.0130.06316.41
5.4.00.0100.06715.46
5.3.290.0130.05314.64
5.3.280.0070.07714.59
5.3.270.0070.07314.44
5.3.260.0130.07014.57
5.3.250.0030.06014.53
5.3.240.0130.06714.58
5.3.230.0130.06714.53
5.3.220.0000.07314.52
5.3.210.0070.07714.52
5.3.200.0100.07314.52
5.3.190.0070.04314.50
5.3.180.0100.08014.43
5.3.170.0100.07714.56
5.3.160.0100.07014.39
5.3.150.0100.07714.56
5.3.140.0100.07314.50
5.3.130.0030.04314.43
5.3.120.0070.07714.50
5.3.110.0130.06714.38
5.3.100.0100.07714.03
5.3.90.0100.06714.02
5.3.80.0130.06713.79
5.3.70.0100.05013.89
5.3.60.0030.07713.87
5.3.50.0030.08013.92
5.3.40.0070.07713.87
5.3.30.0030.07713.92
5.3.20.0100.06713.61
5.3.10.0170.06313.47
5.3.00.0070.04013.51
5.2.170.0070.05710.95
5.2.160.0070.06011.15
5.2.150.0030.06711.18
5.2.140.0070.06711.18
5.2.130.0000.06311.11
5.2.120.0100.05711.10
5.2.110.0030.06711.11
5.2.100.0070.06011.14
5.2.90.0070.06010.98
5.2.80.0000.03710.96
5.2.70.0100.06011.11
5.2.60.0030.06011.07
5.2.50.0100.05311.10
5.2.40.0030.05311.00
5.2.30.0030.06310.83
5.2.20.0000.06711.03
5.2.10.0100.05710.82
5.2.00.0030.06710.79
5.1.60.0070.05710.04
5.1.50.0100.04710.03
5.1.40.0100.03310.03
5.1.30.0030.05710.36
5.1.20.0000.06310.41
5.1.10.0130.04710.12
5.1.00.0070.05010.11
5.0.50.0130.0409.46
5.0.40.0030.0479.46
5.0.30.0000.0679.46
5.0.20.0030.0479.46
5.0.10.0030.0439.46
5.0.00.0070.0579.46
4.4.90.0000.0379.46
4.4.80.0000.0379.46
4.4.70.0070.0379.46
4.4.60.0000.0409.46
4.4.50.0070.0239.46
4.4.40.0070.0409.46
4.4.30.0030.0379.46
4.4.20.0000.0379.46
4.4.10.0070.0309.46
4.4.00.0030.0579.46
4.3.110.0070.0339.46
4.3.100.0000.0379.46
4.3.90.0030.0379.46
4.3.80.0030.0439.46
4.3.70.0030.0309.46
4.3.60.0030.0339.46
4.3.50.0000.0379.46
4.3.40.0030.0539.46
4.3.30.0000.0379.46
4.3.20.0070.0279.46
4.3.10.0000.0409.46
4.3.00.0000.0339.46

preferences:
37.53 ms | 400 KiB | 5 Q