3v4l.org

run code in 300+ PHP versions simultaneously
<?php $x = ['1', '2']; $y = ['2', '1']; $z = ['1', '2', '4']; $n = [1, 2]; echo array_diff($x, $y) === array_diff($y, $x) ? 'y1' : 'n1'; echo array_diff($x) === array_diff($z) ? 'y2' : 'n2'; echo array_diff($z); echo array_diff($x) === array_diff($n) ? 'y3' : 'n3';

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.0100.00618.38
8.3.50.0000.01718.28
8.3.40.0180.00018.72
8.3.30.0070.00718.58
8.3.20.0040.00418.56
8.3.10.0090.00021.59
8.3.00.0040.00420.52
8.2.180.0110.00718.13
8.2.170.0090.00622.96
8.2.160.0150.00021.07
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0000.00718.01
8.2.120.0060.00326.35
8.2.110.0060.00322.08
8.2.100.0070.00417.60
8.2.90.0060.00317.75
8.2.80.0040.00417.97
8.2.70.0040.00417.93
8.2.60.0080.00018.22
8.2.50.0000.00718.10
8.2.40.0000.00719.36
8.2.30.0040.00419.22
8.2.20.0040.00417.92
8.2.10.0000.00718.02
8.2.00.0080.00017.48
8.1.280.0070.00725.92
8.1.270.0040.00418.95
8.1.260.0070.00026.35
8.1.250.0040.00428.09
8.1.240.0060.00322.46
8.1.230.0070.00417.56
8.1.220.0040.00417.74
8.1.210.0000.00918.77
8.1.200.0110.00016.75
8.1.190.0040.00417.10
8.1.180.0060.00318.10
8.1.170.0000.00918.49
8.1.160.0000.00718.92
8.1.150.0070.00018.77
8.1.140.0080.00022.16
8.1.130.0040.00420.01
8.1.120.0070.00017.30
8.1.110.0030.00617.39
8.1.100.0030.00317.37
8.1.90.0000.00717.34
8.1.80.0080.00017.30
8.1.70.0000.00717.32
8.1.60.0060.00317.53
8.1.50.0000.00717.34
8.1.40.0080.00017.47
8.1.30.0050.00317.50
8.1.20.0000.00717.41
8.1.10.0050.00217.46
8.1.00.0000.00717.41
8.0.300.0040.00418.77
8.0.290.0040.00416.75
8.0.280.0080.00318.47
8.0.270.0080.00017.29
8.0.260.0030.00318.44
8.0.250.0000.00616.92
8.0.240.0030.00317.07
8.0.230.0060.00016.80
8.0.220.0060.00316.90
8.0.210.0070.00016.88
8.0.200.0000.00616.88
8.0.190.0000.00716.88
8.0.180.0040.00416.79
8.0.170.0030.00616.91
8.0.160.0000.00716.88
8.0.150.0030.00316.86
8.0.140.0000.00716.87
8.0.130.0030.00313.31
8.0.120.0040.00416.81
8.0.110.0040.00416.82
8.0.100.0000.00816.76
8.0.90.0040.00416.99
8.0.80.0100.01016.90
8.0.70.0000.00716.89
8.0.60.0020.00516.68
8.0.50.0050.00316.87
8.0.30.0090.00917.05
8.0.20.0180.00517.40
8.0.10.0040.00416.87
8.0.00.0100.01916.69
7.4.330.0020.00215.55
7.4.320.0030.00316.58
7.4.300.0000.00616.43
7.4.290.0030.00316.39
7.4.280.0020.00516.47
7.4.270.0040.00416.58
7.4.260.0030.00316.45
7.4.250.0050.00216.42
7.4.240.0030.00316.57
7.4.230.0000.00716.39
7.4.220.0040.00416.63
7.4.210.0070.01016.51
7.4.200.0040.00616.47
7.4.160.0070.00916.48
7.4.140.0130.00517.86
7.4.130.0130.00616.64
7.4.120.0090.00916.56
7.4.110.0100.00716.51
7.4.100.0060.01116.42
7.4.90.0140.00316.55
7.4.80.0040.01319.39
7.4.70.0070.01016.64
7.4.60.0030.01416.36
7.4.50.0130.00016.54
7.4.40.0090.00916.43
7.3.330.0020.00213.15
7.3.320.0030.00313.27
7.3.310.0030.00316.25
7.3.300.0070.00016.16
7.3.290.0030.00316.29
7.3.280.0040.01116.27
7.3.260.0090.01116.35
7.3.240.0070.01016.36
7.3.230.0030.01416.21
7.3.210.0110.00716.40
7.3.200.0080.00816.23
7.3.190.0080.00816.30
7.3.180.0060.00916.24
7.3.170.0110.01116.29
7.3.160.0060.00916.29
7.2.330.0150.00316.54
7.2.320.0120.01216.50
7.2.310.0040.01216.62
7.2.300.0030.01316.39
7.2.290.0090.00816.34

preferences:
47.97 ms | 401 KiB | 5 Q