3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array1 = array("a" => "green", "b" => "brown", "c" => "blue", "red"); $array2 = array("a" => "green", "b" => "yellow", "red"); $result = array_diff_key($array1, $array2); var_dump($result, $array1, $array2);

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.0150.00618.18
8.3.50.0100.00722.11
8.3.40.0070.00718.55
8.3.30.0100.00320.17
8.3.20.0050.00320.26
8.3.10.0080.00022.09
8.3.00.0030.00522.46
8.2.180.0070.01116.50
8.2.170.0100.00622.96
8.2.160.0100.00322.26
8.2.150.0050.00324.18
8.2.140.0060.00324.66
8.2.130.0040.00426.16
8.2.120.0040.00420.96
8.2.110.0060.00322.12
8.2.100.0040.00817.59
8.2.90.0040.00419.09
8.2.80.0040.00419.25
8.2.70.0030.00517.50
8.2.60.0040.00417.91
8.2.50.0070.00418.07
8.2.40.0040.00418.16
8.2.30.0030.00617.86
8.2.20.0000.00717.58
8.2.10.0000.00817.78
8.2.00.0000.00917.63
8.1.270.0040.00424.66
8.1.260.0070.00026.35
8.1.250.0060.00328.09
8.1.240.0030.00623.96
8.1.230.0080.00319.11
8.1.220.0000.00917.78
8.1.210.0040.00418.77
8.1.200.0040.00417.10
8.1.190.0070.00017.53
8.1.180.0040.00419.01
8.1.170.0030.00518.57
8.1.160.0040.00422.04
8.1.150.0060.00318.48
8.1.140.0000.00717.38
8.1.130.0030.00317.69
8.1.120.0000.00717.24
8.1.110.0000.00717.41
8.1.100.0000.00717.38
8.1.90.0000.00717.27
8.1.80.0000.00717.29
8.1.70.0080.00017.19
8.1.60.0040.00417.48
8.1.50.0000.00817.49
8.1.40.0000.00817.43
8.1.30.0040.00417.54
8.1.20.0030.00517.64
8.1.10.0020.00517.39
8.1.00.0040.00417.37
8.0.300.0040.00418.77
8.0.290.0000.00717.05
8.0.280.0030.00318.28
8.0.270.0000.00717.07
8.0.260.0030.00316.79
8.0.250.0000.00716.84
8.0.240.0000.00716.78
8.0.230.0000.00716.83
8.0.220.0070.00016.80
8.0.210.0070.00016.81
8.0.200.0000.00716.86
8.0.190.0020.00516.80
8.0.180.0030.00316.74
8.0.170.0000.00816.80
8.0.160.0040.00416.78
8.0.150.0070.00016.80
8.0.140.0040.00416.78
8.0.130.0060.00013.29
8.0.120.0040.00416.77
8.0.110.0040.00416.65
8.0.100.0000.00716.64
8.0.90.0070.00016.68
8.0.80.0130.00616.75
8.0.70.0000.00816.76
8.0.60.0000.00816.77
8.0.50.0040.00416.68
8.0.30.0150.00617.00
8.0.20.0100.01017.40
8.0.10.0040.00416.80
8.0.00.0100.00916.68
7.4.330.0040.00015.00
7.4.320.0030.00316.51
7.4.300.0030.00316.56
7.4.290.0000.00616.51
7.4.280.0040.00416.52
7.4.270.0030.00316.54
7.4.260.0040.00416.50
7.4.250.0050.00316.41
7.4.240.0070.00016.38
7.4.230.0060.00016.56
7.4.220.0090.00916.45
7.4.210.0080.00816.49
7.4.200.0030.00316.36
7.4.190.0050.00316.38
7.4.160.0060.01116.49
7.4.150.0100.00717.40
7.4.140.0120.00817.86
7.4.130.0050.01416.53
7.4.120.0120.00816.37
7.4.110.0110.01416.39
7.4.100.0220.00316.38
7.4.90.0160.01016.21
7.4.80.0100.00619.39
7.4.70.0140.00416.44
7.4.60.0080.00816.11
7.4.50.0080.00016.25
7.4.40.0090.00922.77
7.4.30.0110.00616.59
7.4.00.0060.00914.79
7.3.330.0050.00012.99
7.3.320.0040.00213.06
7.3.310.0070.00016.06
7.3.300.0000.00716.04
7.3.290.0030.01316.04
7.3.280.0080.00716.17
7.3.270.0140.00317.40
7.3.260.0040.01816.18
7.3.250.0110.00716.38
7.3.240.0150.00416.28
7.3.230.0030.01516.45
7.3.210.0110.00516.13
7.3.200.0050.01119.39
7.3.190.0090.01216.08
7.3.180.0080.00816.14
7.3.170.0100.00716.32
7.3.160.0120.00416.32
7.3.120.0070.00714.68
7.2.330.0110.00716.43
7.2.320.0150.00316.45
7.2.310.0060.01216.36
7.2.300.0040.01916.22
7.2.290.0120.01216.34
7.1.200.0030.01015.65
7.1.70.0060.00616.92
7.1.60.0070.01619.43
7.1.50.0000.01316.74
7.1.00.0070.03722.31
7.0.200.0250.00314.77
7.0.140.0070.07321.98
7.0.60.0030.05020.07
7.0.50.0170.06717.84
7.0.40.0000.04719.98
7.0.30.0230.08020.21
7.0.20.0200.05020.04
7.0.10.0130.07720.20
7.0.00.0030.05720.13
5.6.280.0000.08020.90
5.6.210.0130.07320.51
5.6.200.0000.09018.11
5.6.190.0000.04720.60
5.6.180.0400.06720.61
5.6.170.0330.07020.61
5.6.160.0030.05720.70
5.6.150.0000.04318.13
5.6.140.0070.04318.12
5.6.130.0000.04718.14
5.6.120.0100.05021.02
5.6.110.0030.04021.12
5.6.100.0000.04720.97
5.6.90.0000.07720.99
5.6.80.0170.07020.50
5.5.350.0370.06320.33
5.5.340.0070.05717.91
5.5.330.0000.06720.14
5.5.320.0100.05020.29
5.5.310.0200.07720.32
5.5.300.0130.05017.93
5.5.290.0070.08017.91
5.5.280.0030.05720.64
5.5.270.0030.06720.86
5.5.260.0070.03720.75
5.5.250.0070.06320.49
5.5.240.0100.06720.25
5.4.450.0830.05019.55
5.4.440.0730.06019.24
5.4.430.1170.07319.63
5.4.420.0470.05319.32
5.4.410.0100.05319.01
5.4.400.0270.06018.80
5.4.390.0200.06318.57
5.4.380.0100.05718.57
5.4.370.0070.03718.64
5.4.360.0030.05318.47
5.4.350.0130.02911.98
5.4.340.0070.03711.97
5.4.320.0070.04012.45
5.4.310.0060.04012.45
5.4.300.0040.03812.45
5.4.290.0060.03712.45
5.4.280.0050.04212.32
5.4.270.0050.04112.32
5.4.260.0040.04112.32
5.4.250.0090.03712.32
5.4.240.0090.03512.32
5.4.230.0080.03712.31
5.4.220.0080.03512.31
5.4.210.0080.04112.31
5.4.200.0110.03412.31
5.4.190.0080.03512.30
5.4.180.0070.03612.30
5.4.170.0070.03612.32
5.4.160.0080.03612.32
5.4.150.0060.03812.31
5.4.140.0090.03512.00
5.4.130.0060.03511.98
5.4.120.0040.03611.94
5.4.110.0050.03611.94
5.4.100.0060.03411.93
5.4.90.0070.03611.93
5.4.80.0070.03511.93
5.4.70.0060.03411.93
5.4.60.0040.03811.93
5.4.50.0050.03711.93
5.4.40.0080.03311.92
5.4.30.0080.03411.92
5.4.20.0040.03811.92
5.4.10.0060.03711.92
5.4.00.0010.04011.41
5.3.290.0040.04112.80
5.3.280.0050.03912.71
5.3.270.0060.04012.72
5.3.260.0110.04212.72
5.3.250.0110.04812.72
5.3.240.0070.04012.72
5.3.230.0060.03712.71
5.3.220.0060.03612.68
5.3.210.0040.04012.68
5.3.200.0060.03612.68
5.3.190.0060.04412.68
5.3.180.0050.03912.67
5.3.170.0060.03612.67
5.3.160.0070.03512.67
5.3.150.0070.03612.67
5.3.140.0050.03812.66
5.3.130.0040.04112.66
5.3.120.0070.03712.66
5.3.110.0080.03712.66
5.3.100.0090.03412.12
5.3.90.0040.03812.08
5.3.80.0060.03512.08
5.3.70.0100.03612.08
5.3.60.0030.04012.06
5.3.50.0050.03612.00
5.3.40.0030.03912.00
5.3.30.0100.03011.94
5.3.20.0050.03511.70
5.3.10.0050.03511.67
5.3.00.0050.03811.66
5.2.170.0080.0409.15
5.2.160.0050.0359.15
5.2.150.0090.0369.15
5.2.140.0080.0409.15
5.2.130.0090.0389.11
5.2.120.0070.0399.11
5.2.110.0040.0349.12
5.2.100.0070.0279.12
5.2.90.0080.0279.11
5.2.80.0070.0289.11
5.2.70.0040.0319.11
5.2.60.0030.0319.06
5.2.50.0040.0309.03
5.2.40.0060.0279.01
5.2.30.0070.0278.99
5.2.20.0060.0278.97
5.2.10.0050.0288.91
5.2.00.0050.0298.77
5.1.60.0030.0258.05
5.1.50.0060.0228.05
5.1.40.0030.0258.04
5.1.30.0040.0268.38
5.1.20.0040.0278.41
5.1.10.0040.0268.14
5.1.00.0010.0298.13
5.0.50.0050.0196.60
5.0.40.0050.0176.46
5.0.30.0040.0306.27
5.0.20.0030.0196.25
5.0.10.0030.0196.22
5.0.00.0030.0316.21
4.4.90.0040.0144.78
4.4.80.0030.0164.75
4.4.70.0020.0164.75
4.4.60.0030.0154.75
4.4.50.0040.0134.77
4.4.40.0020.0254.71
4.4.30.0040.0144.76
4.4.20.0030.0154.85
4.4.10.0040.0174.85
4.4.00.0050.0264.76
4.3.110.0030.0174.67
4.3.100.0010.0164.67
4.3.90.0040.0134.63
4.3.80.0050.0214.58
4.3.70.0050.0124.63
4.3.60.0030.0194.63
4.3.50.0030.0154.63
4.3.40.0020.0254.54
4.3.30.0040.0143.27
4.3.20.0020.0163.25
4.3.10.0040.0143.22
4.3.00.0130.0308.54

preferences:
43.25 ms | 400 KiB | 5 Q