3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array['addition'] = array(24, 12, 6); $array['subtraction'] = array(4, 4, 2); $array['multiplication'] = array(128, 32, 8); $array['division'] = array(2, 1, 4); $dups = array(); foreach($array as $key => $value){ $dups[$key] = array_count_values($value); } print_r($dups); $currentHighestValue = 1; foreach($dups as $type => $value){ print $type; foreach($value as $key => $value){ if($value > $currentHighestValue){ $currentHighest = $type; } } } print $currentHighest;

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.0140.00416.47
8.3.50.0080.00722.05
8.3.40.0040.01818.85
8.3.30.0070.00719.13
8.3.20.0050.00320.15
8.3.10.0030.00523.56
8.3.00.0040.00419.03
8.2.180.0090.00618.54
8.2.170.0120.00322.96
8.2.160.0100.00320.53
8.2.150.0080.00024.18
8.2.140.0030.00524.66
8.2.130.0060.00326.16
8.2.120.0000.00820.97
8.2.110.0030.00621.89
8.2.100.0040.00717.91
8.2.90.0040.00418.91
8.2.80.0040.00417.97
8.2.70.0030.00617.63
8.2.60.0080.00417.80
8.2.50.0000.00918.07
8.2.40.0000.00821.08
8.2.30.0050.00218.38
8.2.20.0050.00217.77
8.2.10.0080.00018.14
8.2.00.0070.00017.62
8.1.280.0030.01325.92
8.1.270.0030.00623.91
8.1.260.0090.00026.35
8.1.250.0050.00328.09
8.1.240.0040.00423.78
8.1.230.0000.01118.84
8.1.220.0050.00317.79
8.1.210.0040.00418.77
8.1.200.0030.00617.36
8.1.190.0000.00917.36
8.1.180.0050.00318.10
8.1.170.0030.00518.62
8.1.160.0000.00722.05
8.1.150.0000.00818.55
8.1.140.0070.00017.32
8.1.130.0030.00317.82
8.1.120.0030.00317.47
8.1.110.0000.00717.34
8.1.100.0080.00017.48
8.1.90.0070.00017.37
8.1.80.0030.00517.36
8.1.70.0030.00317.46
8.1.60.0050.00317.64
8.1.50.0040.00417.52
8.1.40.0060.00317.42
8.1.30.0050.00317.63
8.1.20.0000.00817.57
8.1.10.0080.00017.61
8.1.00.0040.00417.41
8.0.300.0040.00418.77
8.0.290.0000.00717.05
8.0.280.0030.00318.51
8.0.270.0000.00817.30
8.0.260.0050.00317.28
8.0.250.0060.00016.98
8.0.240.0000.00816.96
8.0.230.0070.00016.96
8.0.220.0000.00716.86
8.0.210.0060.00316.90
8.0.200.0070.00017.00
8.0.190.0050.00316.89
8.0.180.0040.00416.89
8.0.170.0040.00416.81
8.0.160.0040.00416.84
8.0.150.0030.00516.88
8.0.140.0070.00016.77
8.0.130.0000.00713.36
8.0.120.0060.00316.73
8.0.110.0000.00816.80
8.0.100.0030.00416.75
8.0.90.0040.00416.81
8.0.80.0000.01516.90
8.0.70.0040.00416.90
8.0.60.0000.00716.72
8.0.50.0000.00816.75
8.0.30.0120.00817.19
8.0.20.0080.01117.41
8.0.10.0050.00216.88
8.0.00.0090.00916.74
7.4.330.0030.00315.00
7.4.320.0000.00616.50
7.4.300.0000.00616.51
7.4.290.0040.00416.43
7.4.280.0040.00416.55
7.4.270.0030.00316.54
7.4.260.0030.00616.42
7.4.250.0050.00216.32
7.4.240.0020.00516.47
7.4.230.0000.00716.34
7.4.220.0070.01016.40
7.4.210.0060.00816.70
7.4.200.0000.00716.54
7.4.190.0030.00316.31
7.4.160.0100.00716.58
7.4.150.0090.00917.40
7.4.140.0070.01017.86
7.4.130.0090.00716.49
7.4.120.0100.00716.46
7.4.110.0030.01316.56
7.4.100.0070.01416.59
7.4.90.0130.00316.43
7.4.80.0140.00319.39
7.4.70.0150.00016.64
7.4.60.0080.01516.64
7.4.50.0030.00616.50
7.4.40.0040.01216.46
7.4.30.0120.00616.57
7.4.00.0060.00915.03
7.3.330.0040.00413.23
7.3.320.0000.00513.16
7.3.310.0090.00016.41
7.3.300.0030.00316.23
7.3.290.0070.01116.39
7.3.280.0060.01016.28
7.3.270.0140.00417.40
7.3.260.0030.01716.43
7.3.250.0100.00716.43
7.3.240.0070.01416.46
7.3.230.0150.00416.44
7.3.210.0080.00916.67
7.3.200.0110.00519.39
7.3.190.0110.01116.36
7.3.180.0100.00616.63
7.3.170.0100.01016.27
7.3.160.0110.01016.43
7.3.120.0070.00714.78
7.3.110.0080.00814.45
7.3.100.0090.00614.93
7.3.90.0070.01114.56
7.3.80.0030.01014.59
7.3.70.0120.00615.07
7.3.60.0110.00314.97
7.3.50.0080.00314.77
7.3.40.0110.00314.81
7.3.30.0060.00615.04
7.3.20.0030.00616.80
7.3.10.0130.00316.71
7.3.00.0100.00716.60
7.2.330.0060.01216.67
7.2.320.0160.00816.52
7.2.310.0130.00316.69
7.2.300.0090.01416.66
7.2.290.0080.01116.79
7.2.250.0070.01114.93
7.2.240.0060.01214.73
7.2.230.0080.00414.96
7.2.220.0060.01214.98
7.2.210.0070.01314.81
7.2.200.0060.00915.07
7.2.190.0070.00315.13
7.2.180.0120.00314.93
7.2.170.0110.00415.07
7.2.00.0060.00619.45
7.1.330.0070.00715.96
7.1.320.0100.00315.83
7.1.310.0090.00815.89
7.1.300.0000.01415.88
7.1.290.0000.01715.94
7.1.280.0040.01115.84
7.1.270.0090.00315.91
7.1.260.0070.01015.93
7.1.100.0000.01118.19
7.1.70.0060.01016.96
7.1.60.0110.01419.46
7.1.50.0140.00716.78
7.1.00.0070.07322.40
7.0.200.0090.00516.77
7.0.140.0030.07321.98
7.0.60.0030.08019.96
7.0.50.0170.06717.83
7.0.40.0100.08320.23
7.0.30.0300.04720.13
7.0.20.0330.05320.21
7.0.10.0070.06320.22
7.0.00.0100.08320.12
5.6.280.0000.07720.82
5.6.210.0070.08720.64
5.6.200.0100.05718.29
5.6.190.0100.05720.39
5.6.180.0100.09020.60
5.6.170.0200.04720.39
5.6.160.0030.06720.46
5.6.150.0030.07318.29
5.6.140.0030.07718.14
5.6.130.0030.05318.21
5.6.120.0030.06020.99
5.6.110.0070.03720.98
5.6.100.0130.04720.97
5.6.90.0030.04720.96
5.6.80.0070.06320.48
5.5.350.3570.04320.40
5.5.340.0070.08317.97
5.5.330.0200.04720.27
5.5.320.0270.06720.23
5.5.310.0130.07720.20
5.5.300.0070.08018.02
5.5.290.0100.07717.98
5.5.280.0070.04020.77
5.5.270.0200.07020.95
5.5.260.0100.04320.75
5.5.250.0030.08020.61
5.5.240.0030.04320.15
5.4.450.0370.04726.09
5.4.440.0200.05323.13
5.4.430.0100.05020.00
5.4.420.0130.03719.48
5.4.410.0130.05019.20
5.4.400.0200.04319.09
5.4.390.0130.04319.06
5.4.380.0200.06718.76
5.4.370.0070.06018.71
5.4.360.0130.06018.69
5.4.350.0130.07718.76
5.4.340.0130.05718.80
5.4.320.0060.03612.48
5.4.310.0050.05012.48
5.4.300.0120.04512.48
5.4.290.0100.04712.48
5.4.280.0080.03712.38
5.4.270.0030.03912.38
5.4.260.0050.04112.38
5.4.250.0070.05412.38
5.4.240.0090.05112.38
5.4.230.0070.04212.38
5.4.220.0110.03712.37
5.4.210.0030.04112.37
5.4.200.0070.04112.38
5.4.190.0070.03812.37
5.4.180.0090.03512.37
5.4.170.0080.03512.38
5.4.160.0090.03712.38
5.4.150.0190.03512.38
5.4.140.0080.03812.06
5.4.130.0040.03912.05
5.4.120.0080.03512.00
5.4.110.0140.03112.00
5.4.100.0050.03912.00
5.4.90.0090.03712.00
5.4.80.0090.03712.00
5.4.70.0060.03711.99
5.4.60.0100.03912.00
5.4.50.0090.04511.99
5.4.40.0090.04511.98
5.4.30.0100.04811.98
5.4.20.0110.04711.98
5.4.10.0090.04711.98
5.4.00.0120.04611.48
5.3.290.0060.05412.80
5.3.280.0070.05312.71
5.3.270.0050.05212.72
5.3.260.0100.04612.72
5.3.250.0100.04312.72
5.3.240.0090.04712.72
5.3.230.0120.04312.71
5.3.220.0100.04212.68
5.3.210.0120.04412.68
5.3.200.0080.05412.68
5.3.190.0110.05812.68
5.3.180.0130.05312.67
5.3.170.0120.05512.67
5.3.160.0120.05312.67
5.3.150.0100.05612.67
5.3.140.0130.05212.66
5.3.130.0080.06012.66
5.3.120.0070.05912.66
5.3.110.0140.05512.66
5.3.100.0110.05212.12
5.3.90.0120.05412.10
5.3.80.0100.05012.08
5.3.70.0070.05112.08
5.3.60.0100.05012.07
5.3.50.0080.05512.02
5.3.40.0100.05212.02
5.3.30.0090.05911.98
5.3.20.0210.06411.75
5.3.10.0110.04811.73
5.3.00.0100.05211.71
5.2.170.0070.0449.21
5.2.160.0080.0429.21
5.2.150.0090.0429.21
5.2.140.0080.0439.21
5.2.130.0100.0419.17
5.2.120.0120.0389.17
5.2.110.0120.0359.18
5.2.100.0060.0429.17
5.2.90.0100.0399.18
5.2.80.0090.0429.17
5.2.70.0090.0439.16
5.2.60.0100.0419.12
5.2.50.0110.0389.09
5.2.40.0100.0339.07
5.2.30.0120.0339.04
5.2.20.0040.0389.03
5.2.10.0070.0338.94
5.2.00.0050.0418.80
5.1.60.0080.0308.09
5.1.50.0120.0288.09
5.1.40.0060.0338.07
5.1.30.0070.0348.42
5.1.20.0080.0348.44
5.1.10.0090.0308.16
5.1.00.0060.0358.16
5.0.50.0060.0276.64
5.0.40.0070.0276.51
5.0.30.0080.0396.32
5.0.20.0030.0226.29
5.0.10.0070.0186.27
5.0.00.0060.0346.26
4.4.90.0050.0224.78
4.4.80.0060.0204.76
4.4.70.0060.0194.76
4.4.60.0020.0214.76
4.4.50.0050.0184.77
4.4.40.0030.0314.71
4.4.30.0040.0204.76
4.4.20.0060.0204.84
4.4.10.0060.0204.85
4.4.00.0030.0324.75
4.3.110.0050.0174.67
4.3.100.0040.0164.66
4.3.90.0030.0174.64
4.3.80.0010.0324.58
4.3.70.0040.0164.63
4.3.60.0050.0164.63
4.3.50.0040.0184.63
4.3.40.0040.0254.54
4.3.30.0030.0163.31
4.3.20.0050.0153.29
4.3.10.0040.0163.24
4.3.00.0030.02016.23

preferences:
48.82 ms | 401 KiB | 5 Q