3v4l.org

run code in 300+ PHP versions simultaneously
<?php // usually, the order of a class definition doesn't matter $a = new A(); class A {} // when extending a class and when the parent is defined before the child, it works as well $b = new B(); class baseB {} class B extends baseB{} // but when we try to reverse the order of definition, it fails, // (though for some reason it says it's C, not baseC cannot be found) try { $c = new C(); } catch (Throwable $e){ echo $e->getMessage();} class C extends baseC {} class BaseC{} // So we could think that the order of definition is important // yet we can define D before baseD this way class D extends baseD {} $d = new D(); class baseD{}

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.0070.00718.43
8.3.50.0040.01516.43
8.3.40.0040.01218.84
8.3.30.0140.00018.79
8.3.20.0000.00721.76
8.3.10.0040.00423.71
8.3.00.0080.00023.61
8.2.180.0210.00025.92
8.2.170.0070.00718.91
8.2.160.0100.00322.96
8.2.150.0070.00025.66
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0040.00419.96
8.2.110.0060.00320.95
8.2.100.0110.00017.97
8.2.90.0050.00317.84
8.2.80.0040.00419.30
8.2.70.0040.00418.03
8.2.60.0060.00317.25
8.2.50.0030.00618.10
8.2.40.0040.00420.54
8.2.30.0040.00419.42
8.2.20.0040.00418.13
8.2.10.0000.00717.82
8.2.00.0040.00418.05
8.1.280.0180.00025.92
8.1.270.0050.00323.97
8.1.260.0000.00826.35
8.1.250.0050.00328.09
8.1.240.0130.00323.79
8.1.230.0110.00021.03
8.1.220.0050.00317.74
8.1.210.0040.00418.77
8.1.200.0000.00817.35
8.1.190.0030.00617.35
8.1.180.0000.00918.10
8.1.170.0060.00318.49
8.1.160.0000.00818.86
8.1.150.0040.00420.27
8.1.140.0040.00417.62
8.1.130.0030.00319.04
8.1.120.0000.00717.52
8.1.110.0030.00517.29
8.1.100.0070.00017.45
8.1.90.0070.00017.48
8.1.80.0050.00217.50
8.1.70.0040.00417.48
8.1.60.0100.00017.57
8.1.50.0030.00517.52
8.1.40.0000.00817.39
8.1.30.0000.00817.64
8.1.20.0060.00317.55
8.1.10.0000.00717.58
8.1.00.0060.00317.44
8.0.300.0020.00520.08
8.0.290.0000.00816.75
8.0.280.0050.00318.32
8.0.270.0080.00016.77
8.0.260.0030.00318.42
8.0.250.0000.00817.02
8.0.240.0070.00317.01
8.0.230.0030.00316.94
8.0.220.0040.00416.84
8.0.210.0000.00816.87
8.0.200.0000.00816.91
8.0.190.0030.00517.02
8.0.180.0000.00716.94
8.0.170.0030.00616.92
8.0.160.0070.00016.96
8.0.150.0000.00716.78
8.0.140.0070.00016.93
8.0.130.0000.00513.45
8.0.120.0000.00716.83
8.0.110.0000.00716.79
8.0.100.0070.00016.96
8.0.90.0000.00716.79
8.0.80.0040.01016.92
8.0.70.0000.00716.93
8.0.60.0040.00416.97
8.0.50.0050.00316.78
8.0.30.0080.01117.14
8.0.20.0130.00917.40
8.0.10.0000.00717.04
8.0.00.0100.00816.67
7.4.330.0000.00515.55
7.4.320.0000.00616.59
7.4.300.0000.00716.62
7.4.290.0000.00716.65
7.4.280.0040.00416.49
7.4.270.0000.00816.62
7.4.260.0000.00716.51
7.4.250.0040.00416.56
7.4.240.0070.00016.59
7.4.230.0000.00716.42
7.4.220.0000.00816.36
7.4.210.0100.01016.70
7.4.200.0000.00716.56
7.4.160.0090.00616.66
7.4.140.0110.00917.86
7.4.130.0060.01316.63
7.4.120.0100.00716.54
7.4.110.0190.00016.55
7.4.100.0130.00316.46
7.4.90.0070.01016.56
7.4.80.0080.01119.39
7.4.70.0030.01316.46
7.4.60.0100.00716.59
7.4.50.0040.00716.16
7.4.40.0030.01316.43
7.4.10.0000.01914.78
7.4.00.0050.01015.00
7.3.330.0050.00013.25
7.3.320.0060.00013.30
7.3.310.0040.00416.13
7.3.300.0070.00016.25
7.3.290.0070.01116.27
7.3.280.0060.00916.33
7.3.260.0130.00616.55
7.3.250.0120.00516.36
7.3.240.0100.00716.50
7.3.230.0030.01416.36
7.3.210.0080.00816.33
7.3.200.0090.01216.25
7.3.190.0120.00316.34
7.3.180.0060.01016.52
7.3.170.0070.01016.43
7.3.160.0150.00416.44
7.3.130.0130.00314.63
7.3.120.0120.00614.71
7.3.110.0130.00615.02
7.3.100.0110.00414.99
7.3.90.0080.00814.95
7.3.80.0040.00815.12
7.3.70.0000.01514.78
7.3.60.0110.00314.93
7.3.50.0140.00014.70
7.3.40.0090.00014.82
7.3.30.0030.01014.64
7.3.20.0090.00316.33
7.3.10.0120.00316.45
7.3.00.0070.00716.50
7.2.330.0100.00716.80
7.2.320.0040.01416.29
7.2.310.0040.01316.43
7.2.300.0100.00716.79
7.2.290.0110.01416.72
7.2.260.0040.01414.94
7.2.250.0070.01015.04
7.2.240.0090.00615.25
7.2.230.0090.01214.95
7.2.220.0030.01015.32
7.2.210.0000.00914.94
7.2.200.0100.00615.15
7.2.190.0070.00714.97
7.2.180.0100.00715.22
7.2.170.0030.00615.11
7.2.160.0120.00614.83
7.2.150.0030.00917.05
7.2.140.0000.01217.01
7.2.130.0000.01216.92
7.2.120.0060.00916.90
7.2.110.0120.00317.08
7.2.100.0160.00016.73
7.2.90.0140.00016.91
7.2.80.0080.00816.92
7.2.70.0060.00817.14
7.2.60.0060.00617.07
7.2.50.0000.01317.02
7.2.40.0000.01216.98
7.2.30.0120.01117.80
7.2.20.0120.01117.68
7.2.10.0110.01417.86
7.2.00.0090.01317.85
7.1.330.0090.00615.94
7.1.320.0060.00915.78
7.1.310.0030.00815.40
7.1.300.0070.01015.64
7.1.290.0060.00615.71
7.1.280.0090.00615.35
7.1.270.0070.00415.72
7.1.260.0030.00915.57
7.1.250.0070.00715.75
7.1.240.0110.00415.72
7.1.230.0030.00715.61
7.1.220.0030.00715.71
7.1.210.0070.01015.82
7.1.200.0040.00615.57
7.1.190.0080.00415.51
7.1.180.0060.00615.65
7.1.170.0060.00615.71
7.1.160.0110.00415.80
7.1.150.0110.01116.47
7.1.140.0160.01016.38
7.1.130.0390.01316.54
7.1.120.0120.01216.45
7.1.110.0090.01115.83
7.1.100.0070.01415.95
7.1.90.0100.00815.94
7.1.80.0170.01115.79
7.1.70.0130.01015.33
7.1.60.0240.01428.77
7.1.50.0240.01128.49
7.1.40.0230.01128.25
7.1.30.0230.01228.28
7.1.20.0230.01328.31
7.1.10.0120.00914.87
7.1.00.0100.01114.92
7.0.330.0060.01015.49
7.0.320.0060.00915.35
7.0.310.0030.01015.11
7.0.300.0030.01015.39
7.0.290.0050.00515.24
7.0.280.0100.00315.38
7.0.270.0100.01216.12
7.0.260.0110.01016.18
7.0.250.0100.00815.59
7.0.240.0120.01015.67
7.0.230.0270.00915.67
7.0.220.0090.00915.48
7.0.210.0070.00914.97
7.0.200.0090.00814.93
7.0.190.0070.01215.02
7.0.180.0100.01014.72
7.0.170.0070.01114.70
7.0.160.0100.01014.52
7.0.150.0100.01014.62
7.0.140.0100.01114.69
7.0.130.0110.00814.97
7.0.120.0210.01214.85
7.0.110.0100.01314.70
7.0.100.0100.01014.66
7.0.90.0180.00914.59
7.0.80.0080.01114.82
7.0.70.0100.00914.74
7.0.60.0070.00814.51
7.0.50.0080.01014.69
7.0.40.0080.01214.32
7.0.30.0090.01014.19
7.0.20.0080.01014.28
7.0.10.0100.00814.20
7.0.00.0080.00914.18
5.6.400.0000.00814.13
5.6.390.0110.00014.42
5.6.380.0000.01714.20
5.6.370.0090.00314.40
5.6.360.0030.00914.55
5.6.350.0070.00714.38
5.6.340.0090.00614.44
5.6.330.0070.00714.35
5.6.320.0060.00614.03
5.6.310.0120.00014.72
5.6.300.0140.04519.10
5.6.290.0160.05019.03
5.6.280.0120.04719.32
5.6.270.0130.05219.21
5.6.260.0150.04419.21
5.6.250.0150.04819.10
5.6.240.0130.05119.25
5.6.230.0120.04819.08
5.6.220.0180.04619.23
5.6.210.0140.04719.14
5.6.200.0130.05219.10
5.6.190.0150.05319.16
5.6.180.0160.04919.27
5.6.170.0180.04919.21
5.6.160.0130.04919.18
5.6.150.0150.05119.14
5.6.140.0140.05419.19
5.6.130.0180.04919.23
5.6.120.0190.05919.16
5.6.110.0190.05119.17
5.6.100.0210.06019.13
5.6.90.0140.05019.05
5.6.80.0170.04918.69
5.6.70.0160.04918.69
5.6.60.0130.05018.65
5.6.50.0120.04618.73
5.6.40.0140.04618.70
5.6.30.0110.04818.70
5.6.20.0170.05418.60
5.6.10.0140.04718.65
5.6.00.0130.04718.61
5.5.380.0170.05717.52
5.5.370.0160.05417.50
5.5.360.0160.06217.45
5.5.350.0150.06717.50
5.5.340.0150.06818.02
5.5.330.0160.06317.93
5.5.320.0160.05817.96
5.5.310.0180.06217.85
5.5.300.0180.06418.00
5.5.290.0170.05818.00
5.5.280.0190.06217.93
5.5.270.0180.07017.95
5.5.260.0190.07918.05
5.5.250.0160.06517.87
5.5.240.0170.06417.24
5.5.230.0150.07317.42
5.5.220.0170.05617.32
5.5.210.0140.05517.41
5.5.200.0140.05417.38
5.5.190.0150.05817.35
5.5.180.0170.07617.38
5.5.160.0160.05417.23
5.5.150.0150.06217.35
5.5.140.0160.06217.24
5.5.130.0140.05317.36
5.5.120.0150.06217.34
5.5.110.0180.06117.35
5.5.100.0130.06117.16
5.5.90.0160.05917.34
5.5.80.0130.05317.17
5.5.70.0150.06717.20
5.5.60.0200.06817.02
5.5.50.0150.05517.30
5.5.40.0130.05517.24
5.5.30.0190.05717.27
5.5.20.0180.05917.19
5.5.10.0150.05517.07
5.5.00.0120.06617.29
5.4.450.0230.07019.40
5.4.440.0150.06119.38
5.4.430.0240.06819.38
5.4.420.0170.05919.43
5.4.410.0180.06319.29
5.4.400.0190.05919.04
5.4.390.0160.06519.05
5.4.380.0160.05919.09
5.4.370.0140.06018.96
5.4.360.0150.06019.08
5.4.350.0180.05819.04
5.4.340.0160.06318.97
5.4.320.0130.06519.07
5.4.310.0130.06218.91
5.4.300.0180.05719.00
5.4.290.0180.05319.06
5.4.280.0170.05919.07
5.4.270.0150.06018.92
5.4.260.0210.05719.10
5.4.250.0200.06119.02
5.4.240.0180.05818.93
5.4.230.0180.05319.00
5.4.220.0170.05918.99
5.4.210.0150.06019.10
5.4.200.0160.06219.09
5.4.190.0170.05319.02
5.4.180.0180.06219.13
5.4.170.0200.06019.04
5.4.160.0160.06718.99
5.4.150.0180.05518.99
5.4.140.0150.06216.65
5.4.130.0140.04916.71
5.4.120.0150.06116.68
5.4.110.0150.06516.60
5.4.100.0130.05916.62
5.4.90.0120.05216.72
5.4.80.0120.05116.62
5.4.70.0150.05916.61
5.4.60.0160.05316.53
5.4.50.0150.04816.46
5.4.40.0170.05616.68
5.4.30.0150.05216.62
5.4.20.0140.05716.59
5.4.10.0170.06016.52
5.4.00.0170.06015.91
5.3.290.0150.05914.84
5.3.280.0150.05414.81
5.3.270.0160.06514.69
5.3.260.0160.05614.79
5.3.250.0160.05814.86
5.3.240.0120.05814.74
5.3.230.0170.06514.81
5.3.220.0130.05914.75
5.3.210.0150.06414.76
5.3.200.0160.04914.68
5.3.190.0130.05514.57
5.3.180.0180.06314.64
5.3.170.0170.06914.69
5.3.160.0130.05514.77
5.3.150.0120.06114.84
5.3.140.0150.05114.61
5.3.130.0150.06214.76
5.3.120.0130.06814.74
5.3.110.0150.06114.73
5.3.100.0140.05614.15
5.3.90.0170.06214.28
5.3.80.0120.06314.09
5.3.70.0150.06114.07
5.3.60.0190.05414.20
5.3.50.0160.05313.99
5.3.40.0170.05014.17
5.3.30.0140.05414.09
5.3.20.0170.04913.69
5.3.10.0120.05513.75
5.3.00.0160.06313.84
5.2.170.0110.04811.25
5.2.160.0090.04311.33
5.2.150.0130.04311.25
5.2.140.0120.04311.24
5.2.130.0110.04911.18
5.2.120.0100.04611.22
5.2.110.0110.04311.21
5.2.100.0130.04711.25
5.2.90.0120.04611.29
5.2.80.0130.05011.29
5.2.70.0120.04711.25
5.2.60.0110.05011.11
5.2.50.0120.04011.25
5.2.40.0120.04411.04
5.2.30.0140.04411.23
5.2.20.0140.04511.11
5.2.10.0120.04511.07
5.2.00.0160.04610.91
5.1.60.0120.04610.17
5.1.50.0100.04310.18
5.1.40.0070.04210.09
5.1.30.0100.03610.44
5.1.20.0130.04110.40
5.1.10.0110.04210.23
5.1.00.0120.03310.24
5.0.50.0090.0338.59
5.0.40.0120.0288.47
5.0.30.0090.0478.45
5.0.20.0070.0328.37
5.0.10.0060.0338.35
5.0.00.0080.0418.40
4.4.90.0080.0238.07
4.4.80.0060.0258.07
4.4.70.0060.0258.07
4.4.60.0090.0238.07
4.4.50.0060.0278.07
4.4.40.0060.0438.07
4.4.30.0070.0208.07
4.4.20.0070.0278.07
4.4.10.0050.0268.07
4.4.00.0070.0378.07
4.3.110.0060.0258.07
4.3.100.0080.0268.07
4.3.90.0060.0258.07
4.3.80.0060.0338.07
4.3.70.0060.0208.07
4.3.60.0060.0218.07
4.3.50.0050.0238.07
4.3.40.0070.0388.07
4.3.30.0050.0278.07
4.3.20.0040.0298.07
4.3.10.0060.0238.07
4.3.00.0050.0218.07

preferences:
98.71 ms | 400 KiB | 5 Q