3v4l.org

run code in 300+ PHP versions simultaneously
<?php $anna_array = array("soccer" => "10", "basketball" => "20", "atletics" => "40"); $john_array = array("soccer" => "15", "basketball" => "15", "atletics" => "45"); $common_sports = array_keys(array_intersect_key($anna_array, $john_array)); $points_anna_array = $points_john_array = array_fill_keys($common_sports, 0); foreach ($common_sports as $common_sport) { if ($anna_array[$common_sport] > $john_array[$common_sport]) { $points_anna_array[$common_sport]++; } else if ($anna_array[$common_sport] < $john_array[$common_sport]) { $points_john_array[$common_sport]++; } } echo $points_speler1_array[soccer]; foreach ($common_sports as $common_sport) { echo sprintf( 'Anna(%s) %d vs John(%s) %d'."\n", $common_sport, $points_anna_array[$common_sport], $common_sport, $points_john_array[$common_sport] ); }

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.0190.00318.65
8.3.50.0150.00722.04
8.3.40.0130.00619.01
8.3.30.0030.01018.73
8.3.20.0040.00420.26
8.3.10.0080.00020.51
8.3.00.0070.00021.87
8.2.180.0070.01316.75
8.2.170.0090.00922.96
8.2.160.0040.01522.10
8.2.150.0040.00424.18
8.2.140.0060.00324.66
8.2.130.0060.00321.04
8.2.120.0040.00426.35
8.2.110.0040.00722.26
8.2.100.0060.00618.05
8.2.90.0040.00419.20
8.2.80.0040.00417.97
8.2.70.0080.00017.63
8.2.60.0040.00417.92
8.2.50.0060.00618.09
8.2.40.0040.00420.38
8.2.30.0050.00319.50
8.2.20.0040.00417.72
8.2.10.0030.00618.22
8.2.00.0070.00018.12
8.1.280.0090.01225.92
8.1.270.0090.00922.18
8.1.260.0070.00028.09
8.1.250.0110.00628.09
8.1.240.0000.01020.88
8.1.230.0070.00317.89
8.1.220.0080.00017.79
8.1.210.0000.00918.77
8.1.200.0030.00717.35
8.1.190.0080.00017.36
8.1.180.0000.00818.10
8.1.170.0080.00018.62
8.1.160.0000.00720.75
8.1.150.0000.00718.87
8.1.140.0030.00519.49
8.1.130.0030.00317.76
8.1.120.0040.00417.31
8.1.110.0000.00817.45
8.1.100.0040.00417.53
8.1.90.0070.00017.46
8.1.80.0070.00017.34
8.1.70.0000.00717.41
8.1.60.0050.00217.59
8.1.50.0040.00417.57
8.1.40.0040.00417.55
8.1.30.0050.00317.57
8.1.20.0000.00717.39
8.1.10.0000.00717.61
8.1.00.0000.00817.39
8.0.300.0040.00418.77
8.0.290.0050.00216.75
8.0.280.0030.00318.49
8.0.270.0000.00717.13
8.0.260.0030.00317.28
8.0.250.0000.00617.05
8.0.240.0030.00616.91
8.0.230.0040.00416.91
8.0.220.0070.00316.82
8.0.210.0000.00716.95
8.0.200.0000.00617.00
8.0.190.0000.00716.97
8.0.180.0000.00816.82
8.0.170.0040.00417.03
8.0.160.0030.00517.04
8.0.150.0070.00016.88
8.0.140.0090.00316.85
8.0.130.0030.00313.46
8.0.120.0000.00816.91
8.0.110.0000.00716.81
8.0.100.0040.00417.01
8.0.90.0040.00417.00
8.0.80.0070.01417.00
8.0.70.0030.00517.05
8.0.60.0040.00416.90
8.0.50.0030.00516.97
8.0.30.0080.00716.88
8.0.20.0070.01117.42
8.0.10.0040.00417.01
8.0.00.0090.00816.74
7.4.330.0030.00316.66
7.4.320.0030.00316.59
7.4.300.0000.00616.65
7.4.290.0000.00616.40
7.4.280.0030.00316.60
7.4.270.0050.00516.60
7.4.260.0030.00516.48
7.4.250.0000.00716.57
7.4.240.0040.00416.48
7.4.230.0070.00016.40
7.4.220.0060.01316.54
7.4.210.0030.01016.48
7.4.200.0040.00416.67
7.4.160.0090.00616.48
7.4.150.0060.01217.40
7.4.140.0040.01517.86
7.4.130.0110.01016.44
7.4.120.0140.00216.55
7.4.110.0120.00416.64
7.4.100.0130.00316.48
7.4.90.0120.00916.54
7.4.80.0000.01719.39
7.4.70.0110.00616.58
7.4.60.0070.01016.42
7.4.50.0100.00316.34
7.4.40.0060.01016.47
7.4.30.0160.00016.63
7.4.00.0000.00915.07
7.3.330.0000.00613.24
7.3.320.0060.00013.16
7.3.310.0000.00716.21
7.3.300.0000.00716.41
7.3.290.0060.00816.41
7.3.280.0050.01116.36
7.3.270.0110.00917.40
7.3.260.0190.00016.56
7.3.250.0120.00616.37
7.3.240.0070.01016.38
7.3.230.0120.00916.50
7.3.210.0160.00216.57
7.3.200.0070.01016.66
7.3.190.0060.00916.23
7.3.180.0080.00816.35
7.3.170.0050.01916.39
7.3.160.0130.00316.45
7.2.330.0060.01216.50
7.2.320.0070.01116.73
7.2.310.0060.01316.53
7.2.300.0080.00816.54
7.2.290.0130.00316.61
7.2.60.0030.01316.85
7.2.00.0040.01119.47
7.1.200.0070.00715.79
7.1.100.0090.00917.95
7.1.70.0000.00917.19
7.1.60.0130.01019.24
7.1.50.0070.01016.64
7.1.00.0030.07722.57
7.0.200.0030.01015.11
7.0.60.0400.07020.11
7.0.50.0030.04017.93
7.0.40.0070.05320.19
7.0.30.0230.04320.13
7.0.20.0130.04720.09
7.0.10.0130.08020.19
7.0.00.0030.05020.16
5.6.210.0070.08020.72
5.6.200.0030.04018.13
5.6.190.0100.08320.68
5.6.180.0370.06720.57
5.6.170.0370.07320.49
5.6.160.0070.05020.51
5.6.150.0100.07718.16
5.6.140.0100.06718.12
5.6.130.0070.08318.16
5.6.120.0130.07320.99
5.6.110.0070.09021.01
5.6.100.0070.08320.97
5.6.90.0200.07321.12
5.6.80.0130.05020.39
5.5.350.0270.04020.39
5.5.340.0100.04718.01
5.5.330.0000.08320.29
5.5.320.0200.03720.41
5.5.310.0330.07020.21
5.5.300.0070.04317.95
5.5.290.0070.04017.96
5.5.280.0100.04320.77
5.5.270.0200.07020.95
5.5.260.0070.06720.84
5.5.250.0130.07720.61
5.5.240.0000.08320.35

preferences:
54.12 ms | 401 KiB | 5 Q