3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = array(new stdClass, new stdClass, new stdClass); for ($i = 0; $i < 3; $i++) { for ($j = 0; $j <= $i; $j++) { $x = $array[$i]; $y = $array[$j]; if ($x < $y) print("$i<$j "); if ($x > $y) print("$i>$j "); if ($x == $y) print("$i===$j "); print(" "); } print("\n"); } var_dump(array_udiff()); print("\n"); $array[0]->a = 10; $array[1]->a = 30; $array[2]->a = 20; for ($i = 0; $i < 3; $i++) { for ($j = 0; $j <= $i; $j++) { $x = $array[$i]; $y = $array[$j]; if ($x < $y) print("$i<$j "); if ($x > $y) print("$i>$j "); if ($x == $y) print("$i===$j "); print(" "); } print("\n"); }

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.0110.00416.48
8.3.50.0100.01022.84
8.3.40.0110.00418.71
8.3.30.0130.00619.05
8.3.20.0040.00420.25
8.3.10.0030.00523.71
8.3.00.0080.00019.51
8.2.180.0040.01118.41
8.2.170.0100.00722.96
8.2.160.0090.00920.28
8.2.150.0080.00024.18
8.2.140.0080.00024.66
8.2.130.0040.00426.16
8.2.120.0070.00020.89
8.2.110.0030.00620.53
8.2.100.0040.00718.09
8.2.90.0000.00819.34
8.2.80.0040.00417.97
8.2.70.0000.00817.63
8.2.60.0050.00318.05
8.2.50.0040.00418.07
8.2.40.0040.00417.91
8.2.30.0000.00718.14
8.2.20.0000.00817.73
8.2.10.0050.00318.05
8.2.00.0040.00417.88
8.1.280.0040.01825.92
8.1.270.0050.00323.70
8.1.260.0070.00026.35
8.1.250.0060.00328.09
8.1.240.0070.00423.83
8.1.230.0100.00019.09
8.1.220.0040.00417.77
8.1.210.0030.00618.77
8.1.200.0060.00317.35
8.1.190.0060.00317.25
8.1.180.0000.00818.10
8.1.170.0040.00418.64
8.1.160.0030.00522.07
8.1.150.0030.00519.01
8.1.140.0000.00717.35
8.1.130.0070.00017.76
8.1.120.0050.00217.48
8.1.110.0040.00417.46
8.1.100.0000.00717.45
8.1.90.0050.00217.49
8.1.80.0070.00017.39
8.1.70.0000.00717.45
8.1.60.0030.00917.49
8.1.50.0030.00517.52
8.1.40.0000.00817.59
8.1.30.0050.00317.51
8.1.20.0080.00017.64
8.1.10.0000.00817.61
8.1.00.0040.00417.39
8.0.300.0040.00418.77
8.0.290.0040.00416.88
8.0.280.0070.00018.38
8.0.270.0030.00317.27
8.0.260.0000.00617.36
8.0.250.0000.00717.04
8.0.240.0030.00617.09
8.0.230.0040.00416.97
8.0.220.0030.00316.87
8.0.210.0040.00416.95
8.0.200.0070.00016.90
8.0.190.0050.00317.07
8.0.180.0040.00416.89
8.0.170.0040.00416.88
8.0.160.0000.00717.00
8.0.150.0020.00516.84
8.0.140.0000.00816.83
8.0.130.0030.00313.43
8.0.120.0050.00316.94
8.0.110.0050.00216.96
8.0.100.0050.00317.04
8.0.90.0090.00016.96
8.0.80.0090.01216.92
8.0.70.0040.00416.77
8.0.60.0030.00616.99
8.0.50.0000.00716.93
8.0.30.0100.00917.29
8.0.20.0090.01017.40
8.0.10.0040.00417.01
8.0.00.0080.01016.87
7.4.330.0000.00515.09
7.4.320.0030.00316.61
7.4.300.0000.00616.62
7.4.290.0000.00716.43
7.4.280.0040.00316.53
7.4.270.0030.00316.55
7.4.260.0040.00416.60
7.4.250.0000.00716.49
7.4.240.0050.00316.57
7.4.230.0000.00716.59
7.4.220.0150.00316.46
7.4.210.0080.00816.48
7.4.200.0050.00216.56
7.4.160.0160.00016.56
7.4.150.0060.01117.40
7.4.140.0120.00617.86
7.4.130.0060.01016.54
7.4.120.0130.00416.57
7.4.110.0190.00416.70
7.4.100.0100.01416.68
7.4.90.0100.00716.50
7.4.80.0080.01019.39
7.4.70.0160.00316.68
7.4.60.0070.01016.49
7.4.50.0030.00616.50
7.4.40.0090.01016.60
7.4.30.0040.01216.56
7.4.00.0060.00814.98
7.3.330.0030.00313.21
7.3.320.0020.00213.39
7.3.310.0000.00716.36
7.3.300.0030.00316.36
7.3.290.0100.01016.48
7.3.280.0110.01116.41
7.3.270.0070.01017.40
7.3.260.0140.01016.45
7.3.250.0070.01016.53
7.3.240.0190.00316.73
7.3.230.0070.01116.49
7.3.210.0100.01316.57
7.3.200.0130.00719.39
7.3.190.0040.01216.58
7.3.180.0080.01116.40
7.3.170.0070.01016.41
7.3.160.0120.00616.50
7.3.120.0060.00914.93
7.3.110.0030.00814.90
7.3.100.0070.00715.09
7.3.90.0070.01014.86
7.3.80.0040.00714.84
7.3.70.0060.01014.69
7.3.60.0110.00414.99
7.3.50.0040.01214.73
7.3.40.0060.00614.89
7.3.30.0100.00314.80
7.3.20.0030.00916.81
7.3.10.0050.00416.74
7.3.00.0100.00316.70
7.2.330.0070.01016.53
7.2.320.0060.01316.80
7.2.310.0100.00716.62
7.2.300.0050.01416.81
7.2.290.0040.01916.82
7.2.250.0030.01215.35
7.2.240.0150.00315.01
7.2.230.0080.00414.83
7.2.220.0070.00715.11
7.2.210.0040.01114.73
7.2.200.0040.00815.28
7.2.190.0090.00614.98
7.2.180.0130.00315.25
7.2.170.0030.00715.32
7.2.00.0030.01219.70
7.1.330.0060.00916.02
7.1.320.0000.01015.89
7.1.310.0060.00915.82
7.1.300.0030.00915.66
7.1.290.0030.01015.94
7.1.280.0080.00815.63
7.1.270.0070.00715.88
7.1.260.0040.00415.95
7.1.100.0190.00317.74
7.1.70.0040.00417.27
7.1.60.0060.01019.46
7.1.50.0120.01216.69
7.1.00.0030.07722.54
7.0.200.0030.00316.82
7.0.140.0070.07321.95
7.0.60.0030.08320.05
7.0.50.0070.05017.93
7.0.40.0000.06020.04
7.0.30.0270.06020.00
7.0.20.0270.06320.00
7.0.10.0100.04320.16
7.0.00.0100.06320.30
5.6.280.0000.07721.07
5.6.210.0200.06020.70
5.6.200.0070.06718.15
5.6.190.0030.05320.43
5.6.180.0230.08720.60
5.6.170.0270.04020.54
5.6.160.0100.08320.33
5.6.150.0030.04018.18
5.6.140.0070.08318.18
5.6.130.0130.07018.21
5.6.120.0130.07721.02
5.6.110.0100.08020.98
5.6.100.0070.08321.05
5.6.90.0100.04021.00
5.6.80.0070.04020.41
5.6.70.2270.03720.50
5.5.350.0130.08020.41
5.5.340.0070.08017.95
5.5.330.0000.09320.42
5.5.320.0030.05020.19
5.5.310.0430.07320.41
5.5.300.0100.08017.87
5.5.290.0030.08017.98
5.5.280.0070.05320.79
5.5.270.0170.04320.79
5.5.260.0030.08720.77
5.5.250.0030.09020.69
5.5.240.0130.06020.27
5.4.450.0330.03019.39
5.4.440.0200.04719.09
5.4.430.0100.03719.45
5.4.420.0100.04719.13
5.4.410.0200.04019.00
5.4.400.0630.03319.14
5.4.390.0370.04319.25
5.4.380.0300.05318.67
5.4.370.0370.05318.71
5.4.360.0470.05718.58
5.4.350.0430.05318.71
5.4.340.0430.04018.71
5.4.320.0050.03712.46
5.4.310.0090.03512.46
5.4.300.0060.03612.46
5.4.290.0060.03812.46
5.4.280.0090.03212.36
5.4.270.0030.03812.36
5.4.260.0060.03712.36
5.4.250.0100.03612.36
5.4.240.0040.03812.36
5.4.230.0040.04012.35
5.4.220.0100.03212.35
5.4.210.0050.03612.35
5.4.200.0070.03612.35
5.4.190.0090.03212.35
5.4.180.0110.03012.34
5.4.170.0060.03612.36
5.4.160.0070.03412.35
5.4.150.0080.03312.35
5.4.140.0040.03812.04
5.4.130.0050.03512.02
5.4.120.0040.03611.98
5.4.110.0060.03411.97
5.4.100.0060.03411.98
5.4.90.0080.03511.97
5.4.80.0060.03611.98
5.4.70.0080.03211.97
5.4.60.0050.03511.97
5.4.50.0050.03511.97
5.4.40.0080.03211.96
5.4.30.0040.03711.96
5.4.20.0080.03311.96
5.4.10.0090.03211.96
5.4.00.0050.03611.45
5.3.290.0070.04212.80
5.3.280.0060.03612.71
5.3.270.0040.04012.72
5.3.260.0070.03812.72
5.3.250.0090.03512.72
5.3.240.0080.03512.72
5.3.230.0090.03612.71
5.3.220.0050.03812.68
5.3.210.0060.03912.68
5.3.200.0070.03612.68
5.3.190.0080.03712.68
5.3.180.0080.03912.67
5.3.170.0080.04812.67
5.3.160.0070.04712.68
5.3.150.0080.03812.68
5.3.140.0090.03512.66
5.3.130.0080.04012.66
5.3.120.0060.03812.66
5.3.110.0110.03712.66
5.3.100.0090.03512.12
5.3.90.0100.03312.09
5.3.80.0070.03612.07
5.3.70.0090.03412.07
5.3.60.0080.03412.06
5.3.50.0070.03712.00
5.3.40.0040.04012.00
5.3.30.0080.03411.96
5.3.20.0070.03511.74
5.3.10.0070.03411.70
5.3.00.0040.03811.70
5.2.170.0060.0309.20
5.2.160.0030.0339.20
5.2.150.0050.0319.20
5.2.140.0060.0319.19
5.2.130.0040.0299.15
5.2.120.0040.0289.15
5.2.110.0070.0269.16
5.2.100.0050.0289.16
5.2.90.0050.0299.16
5.2.80.0060.0299.15
5.2.70.0020.0329.15
5.2.60.0070.0289.11
5.2.50.0040.0319.07
5.2.40.0060.0289.05
5.2.30.0080.0279.03
5.2.20.0060.0289.02
5.2.10.0030.0298.96
5.2.00.0070.0278.82
5.1.60.0050.0268.10
5.1.50.0030.0268.09
5.1.40.0060.0228.07
5.1.30.0050.0278.43
5.1.20.0060.0268.45
5.1.10.0090.0228.17
5.1.00.0060.0258.17
5.0.50.0040.0206.66
5.0.40.0030.0206.52
5.0.30.0030.0326.33
5.0.20.0060.0186.30
5.0.10.0050.0236.28
5.0.00.0060.0306.27
4.4.90.0040.0164.77
4.4.80.0050.0154.75
4.4.70.0020.0164.76
4.4.60.0020.0164.76
4.4.50.0030.0154.77
4.4.40.0040.0244.70
4.4.30.0030.0164.76
4.4.20.0030.0154.85
4.4.10.0040.0144.85
4.4.00.0040.0244.76
4.3.110.0040.0154.66
4.3.100.0010.0174.67
4.3.90.0040.0174.63
4.3.80.0020.0274.58
4.3.70.0040.0144.63
4.3.60.0010.0194.63
4.3.50.0060.0174.63
4.3.40.0020.0244.54
4.3.30.0010.0173.32
4.3.20.0020.0163.30
4.3.10.0030.0143.26
4.3.00.0170.01318.41

preferences:
40.93 ms | 401 KiB | 5 Q