3v4l.org

run code in 300+ PHP versions simultaneously
<?php $b = ['x' => 1, 'y' => 1]; $a = ['x' => 1, 'y' => 2]; if (count(array_diff(array_merge($a, $b), array_intersect($a, $b))) === 0) { echo 'the same'; }

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.00616.36
8.3.50.0090.01121.15
8.3.40.0150.00018.79
8.3.30.0110.00418.77
8.3.20.0040.00418.64
8.3.10.0040.00421.78
8.3.00.0080.00020.94
8.2.180.0060.01016.38
8.2.170.0070.01022.96
8.2.160.0000.01419.21
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0070.00026.16
8.2.120.0000.00820.80
8.2.110.0090.00022.27
8.2.100.0100.00217.84
8.2.90.0090.00018.22
8.2.80.0030.00719.95
8.2.70.0050.00317.50
8.2.60.0040.00417.63
8.2.50.0050.00317.63
8.2.40.0040.00419.35
8.2.30.0000.00720.59
8.2.20.0040.00417.68
8.2.10.0070.00317.87
8.2.00.0120.00417.79
8.1.280.0100.00725.92
8.1.270.0080.00023.59
8.1.260.0080.00026.35
8.1.250.0000.00728.09
8.1.240.0110.00720.95
8.1.230.0060.00620.98
8.1.220.0050.00317.78
8.1.210.0000.00818.77
8.1.200.0040.00417.35
8.1.190.0030.00617.23
8.1.180.0070.00418.10
8.1.170.0040.00417.62
8.1.160.0070.00020.93
8.1.150.0050.00318.88
8.1.140.0090.00418.13
8.1.130.0090.00418.50
8.1.120.0090.00417.73
8.1.110.0090.00517.79
8.1.100.0080.00617.68
8.1.90.0070.00617.70
8.1.80.0070.00617.71
8.1.70.0090.00517.69
8.1.60.0110.00517.80
8.1.50.0120.00417.74
8.1.40.0100.00617.83
8.1.30.0110.00517.86
8.1.20.0130.00417.85
8.1.10.0110.00417.66
8.1.00.0100.00617.65
8.0.300.0040.00419.98
8.0.290.0050.00316.75
8.0.280.0070.00018.46
8.0.270.0080.00616.78
8.0.260.0070.00517.56
8.0.250.0090.00517.14
8.0.240.0100.00417.04
8.0.230.0080.00517.04
8.0.220.0100.00516.96
8.0.210.0080.00416.92
8.0.200.0080.00517.02
8.0.190.0050.00817.12
8.0.180.0080.00517.08
8.0.170.0100.00317.11
8.0.160.0100.00417.02
8.0.150.0070.00517.00
8.0.140.0090.00516.96
8.0.130.0080.00416.30
8.0.120.0090.00316.94
8.0.110.0070.00417.03
8.0.100.0090.00316.98
8.0.90.0100.00216.98
8.0.80.0100.00517.01
8.0.70.0110.00517.05
8.0.60.0090.00716.99
8.0.50.0110.00416.99
8.0.30.0110.00617.03
8.0.20.0110.00617.22
8.0.10.0080.00817.15
8.0.00.0110.00717.10
7.4.330.0060.00416.16
7.4.320.0080.00716.73
7.4.300.0100.00516.72
7.4.290.0070.00416.68
7.4.280.0110.00416.73
7.4.270.0130.00216.71
7.4.260.0080.00716.71
7.4.250.0130.00216.65
7.4.240.0100.00416.68
7.4.230.0090.00616.72
7.4.220.0120.00416.76
7.4.210.0130.00316.70
7.4.200.0110.00516.68
7.4.190.0120.00416.81
7.4.180.0120.00416.76
7.4.160.0110.00516.69
7.4.150.0090.00516.82
7.4.140.0090.00716.96
7.4.130.0080.00816.58
7.4.120.0100.00616.58
7.4.110.0120.00316.61
7.4.100.0140.00116.60
7.4.90.0060.00816.59
7.4.80.0110.00417.13
7.4.70.0070.00816.63
7.4.60.0080.00716.59
7.4.50.0090.00616.51
7.4.40.0090.00616.51
7.4.30.0120.00316.60
7.4.20.0090.00616.57
7.4.10.0090.00716.64
7.4.00.0110.00616.37
7.3.330.0100.00315.81
7.3.320.0090.00415.88
7.3.310.0090.00416.51
7.3.300.0090.00416.44
7.3.290.0110.00516.37
7.3.280.0100.00716.36
7.3.270.0120.00216.59
7.3.260.0090.00616.43
7.3.250.0100.00716.42
7.3.240.0110.00516.39
7.3.230.0110.00616.43
7.3.220.0090.00616.46
7.3.210.0110.00616.42
7.3.200.0110.00516.40
7.3.190.0100.00516.39
7.3.180.0100.00516.29
7.3.170.0100.00616.38
7.3.160.0080.00816.42
7.3.150.0100.00616.35
7.3.140.0080.00716.37
7.3.130.0090.00616.39
7.3.120.0090.00816.46
7.3.110.0090.00716.34
7.3.100.0110.00516.38
7.3.90.0100.00516.53
7.3.80.0100.00616.16
7.3.70.0080.00716.18
7.3.60.0090.00616.09
7.3.50.0100.00616.00
7.3.40.0080.00715.81
7.3.30.0090.00815.92
7.3.20.0110.00517.01
7.3.10.0120.00416.90
7.3.00.0210.00616.85
7.2.340.0130.00616.52
7.2.330.0120.00616.53
7.2.320.0130.00516.58
7.2.310.0110.00616.51
7.2.300.0090.00916.55
7.2.290.0080.01016.59
7.2.280.0150.00316.58
7.2.270.0100.00916.55
7.2.260.0120.00616.47
7.2.250.0120.00716.49
7.2.240.0140.00516.53
7.2.230.0140.00416.54
7.2.220.0110.00816.51
7.2.210.0100.00716.28
7.2.200.0130.00616.40
7.2.190.0110.00616.21
7.2.180.0100.00816.25
7.2.170.0100.00816.15
7.2.160.0120.00516.08
7.2.150.0120.00717.18
7.2.140.0090.00717.17
7.2.130.0200.00617.00
7.2.120.0290.00917.09
7.2.110.0130.00617.08
7.2.100.0150.00817.10
7.2.90.0170.00717.01
7.2.80.0230.00617.04
7.2.70.0130.00617.01
7.2.60.0110.00717.05
7.2.50.0110.00917.02
7.2.40.0260.00717.07
7.2.30.0320.00717.17
7.2.20.0290.00717.13
7.2.10.0230.00817.12
7.2.00.0260.00517.18
7.1.330.0130.00616.51
7.1.320.0140.00716.56
7.1.310.0140.00616.18
7.1.300.0130.00516.18
7.1.290.0120.00616.20
7.1.280.0100.00816.16
7.1.270.0100.00816.17
7.1.260.0150.00416.07
7.1.250.0240.00615.87
7.1.240.0180.00715.87
7.1.230.0190.00715.92
7.1.220.0160.00715.86
7.1.210.0200.00615.93
7.1.200.0220.00615.89
7.1.190.0140.00715.79
7.1.180.0130.00815.81
7.1.170.0130.00615.81
7.1.160.0200.00815.89
7.1.150.0220.00716.00
7.1.140.0290.00615.94
7.1.130.0340.00615.91
7.1.120.0310.00715.83
7.1.110.0280.00815.88
7.1.100.0260.00715.90
7.1.90.0270.00815.80
7.1.80.0250.00715.86
7.1.70.0310.00715.85
7.1.60.0260.00817.21
7.1.50.0200.00717.22
7.1.40.0240.00817.18
7.1.30.0250.00817.15
7.1.20.0160.00917.13
7.1.10.0210.00715.76
7.1.00.0220.00715.78
7.0.330.0320.00615.52
7.0.320.0150.00715.43
7.0.310.0160.00615.45
7.0.300.0150.00615.53
7.0.290.0280.00515.59
7.0.280.0190.00715.53
7.0.270.0280.00715.58
7.0.260.0290.00515.53
7.0.250.0300.00615.67
7.0.240.0260.00715.60
7.0.230.0240.00615.64
7.0.220.0270.00515.59
7.0.210.0230.00815.58
7.0.200.0210.01015.58
7.0.190.0180.00815.61
7.0.180.0260.00515.50
7.0.170.0320.00815.54
7.0.160.0200.00715.47
7.0.150.0200.00715.50
7.0.140.0290.00615.51
7.0.130.0300.00615.56
7.0.120.0250.00715.58
7.0.110.0250.00715.47
7.0.100.0280.00715.48
7.0.90.0210.00715.46
7.0.80.0190.00715.47
7.0.70.0220.00615.45
7.0.60.0180.00715.49
7.0.50.0210.00715.52
7.0.40.0180.00815.48
7.0.30.0190.00715.53
7.0.20.0160.00915.44
7.0.10.0250.00515.50
7.0.00.0230.00815.40
5.6.400.0120.00915.52
5.6.390.0130.00715.44
5.6.380.0110.00815.33
5.6.370.0110.01015.31
5.6.360.0130.00615.38
5.6.350.0150.00515.44
5.6.340.0150.00615.47
5.6.330.0130.00815.34
5.6.320.0130.00715.37
5.6.310.0110.00915.32
5.6.300.0150.01216.27
5.6.290.0100.01716.22
5.6.280.0120.01816.24
5.6.270.0140.01616.26
5.6.260.0140.01216.29
5.6.250.0140.01216.27
5.6.240.0140.01516.24
5.6.230.0130.01316.27
5.6.220.0110.01616.25
5.6.210.0130.01316.21
5.6.200.0120.01716.30
5.6.190.0140.01416.31
5.6.180.0140.01516.25
5.6.170.0140.01416.28
5.6.160.0150.01316.26
5.6.150.0140.01316.25
5.6.140.0150.01316.26
5.6.130.0130.01416.23
5.6.120.0140.01516.25
5.6.110.0130.01416.21
5.6.100.0130.01516.22
5.6.90.0130.01316.24
5.6.80.0130.01816.11
5.6.70.0130.01416.11
5.6.60.0140.01416.07
5.6.50.0130.01416.08
5.6.40.0140.01516.15
5.6.30.0120.01616.14
5.6.20.0140.01216.09
5.6.10.0140.01316.16
5.6.00.0140.01316.04
5.5.380.0130.01315.47
5.5.370.0130.01415.46
5.5.360.0120.01415.45
5.5.350.0130.01315.50
5.5.340.0120.01515.52
5.5.330.0120.01415.58
5.5.320.0140.01515.53
5.5.310.0120.01715.53
5.5.300.0100.01615.54
5.5.290.0120.01915.49
5.5.280.0120.01515.55
5.5.270.0120.01715.56
5.5.260.0120.01315.51
5.5.250.0140.01215.46
5.5.240.0140.01315.42
5.5.230.0140.01215.40
5.5.220.0110.01715.37
5.5.210.0120.01515.36
5.5.200.0130.01515.40
5.5.190.0110.01515.38
5.5.180.0140.01315.40
5.5.170.0110.00915.07
5.5.160.0140.01115.40
5.5.150.0130.01315.36
5.5.140.0130.01615.39
5.5.130.0130.01315.41
5.5.120.0120.01315.30
5.5.110.0130.01715.35
5.5.100.0110.01615.40
5.5.90.0150.01215.35
5.5.80.0110.01215.38
5.5.70.0130.01115.35
5.5.60.0120.01215.37
5.5.50.0110.01415.41
5.5.40.0140.01115.34
5.5.30.0110.01515.40
5.5.20.0120.01415.41
5.5.10.0120.01315.38
5.5.00.0120.01315.31

preferences:
34.45 ms | 401 KiB | 5 Q