3v4l.org

run code in 300+ PHP versions simultaneously
<?php class cA { /** * Test property for using direct default value */ protected static $item = 'Foo'; /** * Test property for using indirect default value */ protected static $other = 'cA'; public static function method() { print self::$item."\r\n"; // It prints 'Foo' on everyway... :( print self::$other."\r\n"; // We just think that, this one prints 'cA' only, but... :) } public static function setOther($val) { self::$other = $val; // Set a value in this scope. } } class cB extends cA { /** * Test property with redefined default value */ protected static $item = 'mesh';protected static $other = 'ani'; public static function method_set($val1,$val2) { self::$other = "mesh"; self::$item = "ani"; } } //cB::setOther('cB'); // It's cB::method()! cB::method_set(); cB::method(); // It's cA::method()!

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.0180.00418.43
8.3.50.0060.01121.26
8.3.40.0110.00418.82
8.3.30.0160.00020.17
8.3.20.0000.00820.52
8.3.10.0030.00521.09
8.3.00.0050.00223.52
8.2.180.0030.01216.50
8.2.170.0090.00622.96
8.2.160.0070.00720.52
8.2.150.0040.00424.18
8.2.140.0040.00424.66
8.2.130.0040.00426.16
8.2.120.0080.00020.98
8.2.110.0060.00319.09
8.2.100.0040.00817.84
8.2.90.0030.00619.13
8.2.80.0000.00717.97
8.2.70.0090.00017.36
8.2.60.0080.00017.80
8.2.50.0040.00418.07
8.2.40.0050.00317.91
8.2.30.0050.00219.33
8.2.20.0070.00017.66
8.2.10.0000.00717.56
8.2.00.0000.00717.68
8.1.280.0110.00425.92
8.1.270.0060.00323.99
8.1.260.0050.00226.35
8.1.250.0000.00728.09
8.1.240.0030.00623.93
8.1.230.0080.00420.92
8.1.220.0040.00418.77
8.1.210.0060.00319.00
8.1.200.0060.00317.10
8.1.190.0000.00817.50
8.1.180.0040.00418.10
8.1.170.0040.00418.59
8.1.160.0040.00418.82
8.1.150.0040.00418.57
8.1.140.0000.00717.37
8.1.130.0040.00417.78
8.1.120.0040.00417.38
8.1.110.0000.00717.33
8.1.100.0040.00417.32
8.1.90.0020.00517.32
8.1.80.0000.00717.23
8.1.70.0070.00017.30
8.1.60.0080.00417.43
8.1.50.0040.00417.30
8.1.40.0040.00417.47
8.1.30.0040.00417.55
8.1.20.0040.00417.58
8.1.10.0040.00417.48
8.1.00.0050.00217.46
8.0.300.0030.00620.02
8.0.290.0000.00716.93
8.0.280.0030.00318.39
8.0.270.0030.00317.19
8.0.260.0040.00416.89
8.0.250.0000.00816.86
8.0.240.0040.00416.92
8.0.230.0050.00216.87
8.0.220.0030.00316.96
8.0.210.0030.00316.90
8.0.200.0030.00316.87
8.0.190.0060.00316.89
8.0.180.0000.00716.95
8.0.170.0070.00016.89
8.0.160.0030.00516.79
8.0.150.0040.00416.75
8.0.140.0000.00716.86
8.0.130.0080.00013.43
8.0.120.0000.00716.70
8.0.110.0040.00416.82
8.0.100.0050.00216.76
8.0.90.0000.00716.85
8.0.80.0080.00816.90
8.0.70.0070.00016.89
8.0.60.0030.00516.95
8.0.50.0000.00716.77
8.0.30.0140.00517.23
8.0.20.0050.01317.41
8.0.10.0050.00317.00
8.0.00.0080.01016.76
7.4.330.0000.00515.00
7.4.320.0000.00716.28
7.4.300.0030.00316.52
7.4.290.0030.00316.56
7.4.280.0030.00316.52
7.4.270.0060.00016.54
7.4.260.0050.00013.33
7.4.250.0000.00816.47
7.4.240.0000.00816.34
7.4.230.0030.00316.56
7.4.220.0130.00616.63
7.4.210.0080.00616.55
7.4.200.0040.00416.43
7.4.190.0000.00816.40
7.4.160.0120.00916.46
7.4.150.0100.01317.40
7.4.140.0080.01017.86
7.4.130.0110.01016.55
7.4.120.0090.01016.52
7.4.110.0160.00616.39
7.4.100.0080.00916.53
7.4.90.0070.01016.44
7.4.80.0170.00719.39
7.4.70.0090.00916.39
7.4.60.0120.00316.55
7.4.50.0040.00416.53
7.4.40.0070.00722.77
7.4.30.0100.00616.48
7.4.10.0140.00714.75
7.4.00.0050.01114.83
7.3.330.0000.00613.30
7.3.320.0050.00013.23
7.3.310.0030.00316.41
7.3.300.0000.00716.37
7.3.290.0140.00016.42
7.3.280.0140.00416.35
7.3.270.0090.00917.40
7.3.260.0110.00818.24
7.3.250.0080.01216.39
7.3.240.0040.01516.53
7.3.230.0140.00316.57
7.3.210.0040.01416.33
7.3.200.0090.01219.39
7.3.190.0090.01216.35
7.3.180.0170.00616.28
7.3.170.0100.00616.42
7.3.160.0070.01116.44
7.3.130.0110.00714.82
7.3.120.0050.01314.81
7.3.110.0000.01814.87
7.3.100.0000.01414.84
7.3.90.0030.01014.82
7.3.80.0030.01014.83
7.3.70.0030.01114.85
7.3.60.0030.00914.89
7.3.50.0040.01214.93
7.3.40.0120.00314.87
7.3.30.0080.00814.78
7.3.20.0080.00616.66
7.3.10.0080.00416.56
7.3.00.0100.00316.39
7.2.330.0070.01116.31
7.2.320.0180.00316.57
7.2.310.0030.01616.48
7.2.300.0030.01416.29
7.2.290.0060.00916.49
7.2.260.0140.00715.05
7.2.250.0110.00614.68
7.2.240.0000.01314.48
7.2.230.0070.01015.01
7.2.220.0120.00314.66
7.2.210.0110.00015.04
7.2.200.0070.00314.97
7.2.190.0100.00314.68
7.2.180.0060.01014.82
7.2.170.0060.00614.78
7.2.160.0060.00614.94
7.2.150.0060.00316.89
7.2.140.0110.00716.65
7.2.130.0050.00516.84
7.2.120.0040.00716.65
7.2.110.0040.01416.78
7.2.100.0110.00616.62
7.2.90.0070.01016.91
7.2.80.0070.01016.75
7.2.70.0060.00316.84
7.2.60.0080.00616.69
7.2.50.0080.00816.86
7.2.40.0100.00716.89
7.2.30.0050.00516.85
7.2.20.0070.00416.88
7.2.10.0060.00916.91
7.2.00.0070.00618.04
7.1.330.0060.00915.52
7.1.320.0090.00315.66
7.1.310.0030.01315.66
7.1.300.0080.00015.63
7.1.290.0070.00315.63
7.1.280.0090.00315.31
7.1.270.0000.01215.75
7.1.260.0090.00315.48
7.1.250.0040.00815.58
7.1.240.0030.00815.41
7.1.230.0030.01015.70
7.1.220.0000.00915.65
7.1.210.0080.00815.51
7.1.200.0090.00815.53
7.1.190.0060.00615.73
7.1.180.0130.00015.57
7.1.170.0080.00815.34
7.1.160.0060.01015.58
7.1.150.0070.00715.50
7.1.140.0030.01415.42
7.1.130.0000.01515.62
7.1.120.0040.00415.69
7.1.110.0090.00615.35
7.1.100.0070.00916.81
7.1.90.0000.01215.78
7.1.80.0000.01715.76
7.1.70.0040.00716.38
7.1.60.0080.00617.40
7.1.50.0080.01016.14
7.1.40.0000.01115.66
7.1.30.0120.00415.50
7.1.20.0070.00715.36
7.1.10.0040.00415.66
7.1.00.0040.01818.92
7.0.330.0000.01115.48
7.0.320.0080.00015.13
7.0.310.0060.00915.25
7.0.300.0060.00915.04
7.0.290.0100.00315.23
7.0.280.0030.00915.18
7.0.270.0040.01115.38
7.0.260.0100.00315.09
7.0.250.0110.00715.15
7.0.240.0130.00015.42
7.0.230.0100.00015.36
7.0.220.0040.01215.33
7.0.210.0060.00315.48
7.0.200.0070.00115.97
7.0.190.0040.00415.19
7.0.180.0040.00815.49
7.0.170.0030.00715.50
7.0.160.0060.00615.35
7.0.150.0040.00815.20
7.0.140.0080.03718.81
7.0.130.0000.01315.26
7.0.120.0030.01515.09
7.0.110.0030.00915.29
7.0.100.0180.02817.71
7.0.90.0200.04517.66
7.0.80.0130.02917.58
7.0.70.0080.04417.51
7.0.60.0050.02517.65
7.0.50.0090.03817.93
7.0.40.0130.03716.87
7.0.30.0030.04616.71
7.0.20.0120.04316.77
7.0.10.0090.04216.75
7.0.00.0050.03316.82
5.6.400.0030.01014.59
5.6.390.0000.01414.59
5.6.380.0000.01314.01
5.6.370.0060.00614.22
5.6.360.0000.00914.37
5.6.350.0000.01614.58
5.6.340.0030.01314.30
5.6.330.0070.00714.14
5.6.320.0030.00814.50
5.6.310.0040.00814.41
5.6.300.0030.01014.40
5.6.290.0060.00314.47
5.6.280.0000.04517.70
5.6.270.0070.00314.50
5.6.260.0000.01514.24
5.6.250.0050.04517.41
5.6.240.0050.04817.34
5.6.230.0080.04517.55
5.6.220.0130.03517.39
5.6.210.0080.03017.54
5.6.200.0050.04517.70
5.6.190.0050.04317.82
5.6.180.0030.04817.49
5.6.170.0040.04317.72
5.6.160.0070.03717.52
5.6.150.0070.04717.72
5.6.140.0050.04617.65
5.6.130.0050.04317.69
5.6.120.0070.03017.69
5.6.110.0060.04617.71
5.6.100.0080.04317.74
5.6.90.0090.03717.57
5.6.80.0100.04017.36
5.6.70.0050.04717.35
5.6.60.0020.04217.35
5.6.50.0050.04617.28
5.6.40.0020.04617.40
5.6.30.0060.04317.24
5.6.20.0020.02717.36
5.6.10.0100.04517.31
5.6.00.0060.04017.30
5.5.380.0080.04117.36
5.5.370.0090.02517.26
5.5.360.0080.03817.41
5.5.350.0090.03117.40
5.5.340.0050.04617.61
5.5.330.0070.04717.64
5.5.320.0100.02417.44
5.5.310.0070.04417.49
5.5.300.0070.03817.46
5.5.290.0060.04517.34
5.5.280.0100.04317.56
5.5.270.0030.04117.42
5.5.260.0030.05017.68
5.5.250.0130.02717.41
5.5.240.0100.03017.20
5.5.230.0120.03717.26
5.5.220.0070.02717.07
5.5.210.0020.04817.20
5.5.200.0100.04217.17
5.5.190.0070.04217.31
5.5.180.0030.04617.29
5.5.170.0110.00414.41
5.5.160.0100.04517.08
5.5.150.0100.04217.28
5.5.140.0020.05017.27
5.5.130.0100.04017.18
5.5.120.0090.03017.18
5.5.110.0030.04517.10
5.5.100.0070.03817.25
5.5.90.0140.02516.98
5.5.80.0080.04217.02
5.5.70.0090.04217.10
5.5.60.0030.04017.06
5.5.50.0070.02517.22
5.5.40.0020.04717.11
5.5.30.0130.03717.04
5.5.20.0110.03817.13
5.5.10.0070.02717.21
5.5.00.0080.03817.15
5.4.450.0050.04516.30
5.4.440.0130.03616.25
5.4.430.0080.03216.22
5.4.420.0080.02816.29
5.4.410.0110.03516.09
5.4.400.0080.03915.99
5.4.390.0100.04016.12
5.4.380.0030.04116.09
5.4.370.0050.03016.09
5.4.360.0070.03815.99
5.4.350.0050.03616.19
5.4.340.0080.03716.09
5.4.330.0000.01113.13
5.4.320.0040.02316.18
5.4.310.0000.03016.08
5.4.300.0070.02216.13
5.4.290.0090.02216.00
5.4.280.0020.04316.08
5.4.270.0080.03916.15
5.4.260.0080.02816.17
5.4.250.0080.03516.15
5.4.240.0050.03216.14
5.4.230.0070.03716.12
5.4.220.0000.04716.17
5.4.210.0060.03315.98
5.4.200.0080.03316.17
5.4.190.0030.02715.99
5.4.180.0050.03416.03
5.4.170.0020.04716.10
5.4.160.0030.04516.03
5.4.150.0050.04016.17
5.4.140.0080.02814.70
5.4.130.0080.03514.81
5.4.120.0050.04014.82
5.4.110.0020.04214.78
5.4.100.0080.02314.81
5.4.90.0040.02514.79
5.4.80.0040.03714.72
5.4.70.0020.03414.77
5.4.60.0080.03614.81
5.4.50.0050.04114.80
5.4.40.0090.03314.81
5.4.30.0050.03914.72
5.4.20.0090.01914.72
5.4.10.0050.03814.74
5.4.00.0030.03714.52
5.3.290.0070.03813.96
5.3.280.0060.02813.85
5.3.270.0080.03213.89
5.3.260.0100.03813.83
5.3.250.0040.03213.90
5.3.240.0080.03513.93
5.3.230.0080.04013.85
5.3.220.0110.03513.81
5.3.210.0050.03913.84
5.3.200.0070.03813.88
5.3.190.0070.04013.83
5.3.180.0050.03813.85
5.3.170.0070.03813.91
5.3.160.0020.02813.83
5.3.150.0050.03813.86
5.3.140.0070.04413.90
5.3.130.0070.03913.84
5.3.120.0030.03813.89
5.3.110.0090.03913.88
5.3.100.0000.03213.62
5.3.90.0050.03313.61
5.3.80.0030.04013.62
5.3.70.0060.03513.62
5.3.60.0070.02913.56
5.3.50.0070.03013.61
5.3.40.0060.04013.57
5.3.30.0060.02613.49
5.3.20.0050.03913.44
5.3.10.0020.04113.44
5.3.00.0050.03013.35
5.2.170.0070.06311.56
5.2.160.0070.05711.56
5.2.150.0030.06311.56
5.2.140.0100.05311.56
5.2.130.0070.04311.56
5.2.120.0000.05011.56
5.2.110.0030.05311.56
5.2.100.0030.03311.56
5.2.90.0030.05311.56
5.2.80.0030.06311.56
5.2.70.0000.05011.56
5.2.60.0030.06011.56
5.2.50.0030.06311.56
5.2.40.0070.06011.56
5.2.30.0130.05311.56
5.2.20.0070.06011.56
5.2.10.0000.04311.56
5.2.00.0130.05311.56
5.1.60.0030.04711.56
5.1.50.0030.03311.56
5.1.40.0000.05711.56
5.1.30.0030.04311.56
5.1.20.0030.05311.56
5.1.10.0030.05311.56
5.1.00.0070.05311.56
5.0.50.0030.04711.56
5.0.40.0070.03311.56
5.0.30.0100.05711.56
5.0.20.0070.04011.56
5.0.10.0070.04011.56
5.0.00.0000.05011.56
4.4.90.0130.02311.56
4.4.80.0030.03011.56
4.4.70.0070.03011.56
4.4.60.0030.03011.56
4.4.50.0000.03711.56
4.4.40.0070.04011.56
4.4.30.0000.03311.56
4.4.20.0070.01711.56
4.4.10.0000.04011.56
4.4.00.0000.06011.56
4.3.110.0030.03011.56
4.3.100.0100.02711.56
4.3.90.0070.03011.56
4.3.80.0030.05011.56
4.3.70.0100.02311.56
4.3.60.0000.03311.56
4.3.50.0100.03011.56
4.3.40.0000.05311.56
4.3.30.0030.03311.56
4.3.20.0030.03311.56
4.3.10.0000.03011.56
4.3.00.0030.03011.56

preferences:
54.25 ms | 401 KiB | 5 Q