3v4l.org

run code in 300+ PHP versions simultaneously
<?php class Productss{ protected $title; protected $category; const CHANGES_SAVED = 'Wijzigingen opgeslagen'; public function __construct($title, $category){ $this->title = $title; $this->category = $category; } public function someFunction(){ self::CHANGES_SAVED; // CHANGES_SAVED not changeable in this class, it is changeable in a child class } public function getCategory(){ return $this->category; } public function getTitle(){ return $this->title; } } class Order extends Productss{ protected $price; protected $deliver; const CHANGES_SAVED = 'Wijzigingen nu opgeslagen'; public function __construct($title, $category, $price){ parent::__construct($title, $category); $this->price = $price; $this->doWeDeliver(); } public function getPrice(){ return $this->price; } public function getDeliver(){ return $this->deliver; } protected function doWeDeliver(){ $this->deliver = $this->price > 30 ? 'Yes' : 'No' ; } } //$order = new Order('CD Brahms', 'Media', '45'); //echo 'Product :'.$order->getTitle(); //echo 'Categorie :'.$order->getCategory(); //echo 'Prijs :'.$order->getPrice(); //echo 'Gratis bezorging :'.$order->getDeliver(); echo Productss::CHANGES_SAVED.'<br />'; // 300 echo Order::CHANGES_SAVED.'<br />'; // 500

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.00716.75
8.3.50.0070.01117.38
8.3.40.0120.00318.79
8.3.30.0040.01118.71
8.3.20.0080.00018.65
8.3.10.0080.00020.36
8.3.00.0040.00419.13
8.2.180.0070.00716.63
8.2.170.0120.00622.96
8.2.160.0070.00720.84
8.2.150.0040.00424.18
8.2.140.0050.00524.66
8.2.130.0000.00826.16
8.2.120.0040.00420.89
8.2.110.0060.00320.91
8.2.100.0060.00617.78
8.2.90.0030.00619.36
8.2.80.0040.00419.25
8.2.70.0030.00517.50
8.2.60.0040.00417.80
8.2.50.0000.00818.07
8.2.40.0020.00518.03
8.2.30.0000.00717.91
8.2.20.0040.00417.63
8.2.10.0000.00717.59
8.2.00.0040.00417.46
8.1.280.0040.01125.92
8.1.270.0040.00424.66
8.1.260.0100.00026.35
8.1.250.0070.00028.09
8.1.240.0030.00722.41
8.1.230.0110.00021.00
8.1.220.0000.00817.74
8.1.210.0000.00918.90
8.1.200.0030.00617.10
8.1.190.0000.00717.41
8.1.180.0050.00318.10
8.1.170.0030.00618.84
8.1.160.0020.00518.71
8.1.150.0000.00718.51
8.1.140.0040.00417.32
8.1.130.0000.00717.71
8.1.120.0040.00417.29
8.1.110.0050.00317.32
8.1.100.0000.00817.26
8.1.90.0000.00817.28
8.1.80.0000.00717.27
8.1.70.0040.00417.22
8.1.60.0000.00717.54
8.1.50.0060.00317.30
8.1.40.0060.00317.48
8.1.30.0050.00317.48
8.1.20.0000.00817.49
8.1.10.0000.00817.49
8.1.00.0000.00817.39
8.0.300.0080.00020.15
8.0.290.0070.00016.63
8.0.280.0000.00818.33
8.0.270.0070.00017.23
8.0.260.0080.00018.30
8.0.250.0060.00316.78
8.0.240.0030.00316.79
8.0.230.0070.00016.89
8.0.220.0000.00716.86
8.0.210.0000.00816.77
8.0.200.0090.00016.78
8.0.190.0040.00416.89
8.0.180.0040.00416.88
8.0.170.0040.00416.77
8.0.160.0050.00216.91
8.0.150.0070.00016.76
8.0.140.0000.01016.79
8.0.130.0080.00013.19
8.0.120.0050.00216.65
8.0.110.0000.00816.84
8.0.100.0040.00416.61
8.0.90.0070.00016.88
8.0.80.0140.00916.78
8.0.70.0000.00716.75
8.0.60.0000.00716.84
8.0.50.0070.00016.82
8.0.30.0100.01016.93
8.0.20.0090.01016.89
8.0.10.0040.00416.95
8.0.00.0150.00716.62
7.4.330.0000.00512.89
7.4.320.0030.00616.35
7.4.300.0000.00616.44
7.4.290.0000.00716.46
7.4.280.0000.00716.44
7.4.270.0070.00016.44
7.4.260.0030.00313.21
7.4.250.0040.00416.43
7.4.240.0000.00716.35
7.4.230.0040.00416.31
7.4.220.0180.00016.41
7.4.210.0030.01216.46
7.4.200.0030.00316.59
7.4.190.0000.00716.47
7.4.160.0050.01116.49
7.4.150.0090.00916.38
7.4.140.0050.01216.47
7.4.130.0090.00816.53
7.4.120.0070.01016.36
7.4.110.0200.01416.39
7.4.100.0060.01216.48
7.4.90.0100.00716.40
7.4.80.0130.01019.39
7.4.70.0150.00316.55
7.4.60.0090.00916.41
7.4.50.0060.00616.39
7.4.40.0030.00916.29
7.4.30.0060.01016.47
7.4.00.0030.01014.96
7.3.330.0000.00613.11
7.3.320.0050.00013.20
7.3.310.0030.00316.02
7.3.300.0070.00016.24
7.3.290.0030.01416.18
7.3.280.0060.01316.16
7.3.270.0070.01016.39
7.3.260.0150.00916.34
7.3.250.0080.01016.43
7.3.240.0110.00416.27
7.3.230.0060.01016.31
7.3.210.0110.00516.25
7.3.200.0160.00016.37
7.3.190.0100.01016.41
7.3.180.0040.01216.42
7.3.170.0090.00916.20
7.3.160.0030.01416.42
7.3.120.0060.00917.15
7.3.110.0090.00617.15
7.3.100.0100.00717.15
7.3.90.0000.01417.15
7.3.80.0100.00717.15
7.3.70.0030.01017.15
7.3.60.0030.01317.15
7.3.50.0060.00617.15
7.3.40.0000.01417.15
7.3.30.0110.00017.15
7.3.20.0100.00617.15
7.3.10.0070.01117.15
7.3.00.0100.00717.15
7.2.330.0120.00616.49
7.2.320.0080.00816.47
7.2.310.0030.01916.44
7.2.300.0090.00616.65
7.2.290.0000.02216.33
7.2.240.0080.00817.15
7.2.230.0060.01117.15
7.2.220.0030.01017.15
7.2.210.0090.00617.15
7.2.200.0060.00617.15
7.2.190.0070.00717.15
7.2.180.0130.00317.15
7.2.170.0000.01617.15
7.2.160.0070.01117.15
7.2.150.0100.00717.15
7.2.140.0040.01117.15
7.2.130.0070.01017.15
7.2.120.0000.01517.15
7.2.110.0110.00417.15
7.2.100.0060.01017.15
7.2.90.0160.00017.15
7.2.80.0060.00617.15
7.2.70.0110.00617.15
7.2.60.0110.00717.15
7.2.50.0090.00317.15
7.2.40.0070.01117.15
7.2.30.0100.00617.15
7.2.20.0120.00617.15
7.2.10.0040.01417.15
7.2.00.0100.00317.15
7.1.330.0030.01017.15
7.1.320.0070.01017.15
7.1.310.0000.00817.15
7.1.300.0060.00717.15
7.1.290.0000.01417.15
7.1.280.0040.01117.15
7.1.270.0000.01617.15
7.1.260.0060.00917.15
7.1.250.0040.01117.15
7.1.70.0000.00816.98
7.1.60.0100.01619.40
7.1.50.0030.01716.74
7.1.00.0030.04722.36
7.0.200.0100.00316.69
7.0.140.0000.07721.98
7.0.120.0030.07322.03
7.0.60.0070.08319.94
7.0.50.0130.07317.87
7.0.40.0100.08317.88
7.0.30.0070.06317.76
7.0.20.0100.08017.71
7.0.10.0070.07717.69
7.0.00.0030.08317.85
5.6.280.0130.06320.93
5.6.210.0070.08720.52
5.6.200.0000.05718.18
5.6.190.0030.08318.20
5.6.180.0070.04018.15
5.6.170.0000.04318.29
5.6.160.0130.07318.18
5.6.150.0070.08018.19
5.6.140.0070.08018.15
5.6.130.0170.07018.15
5.6.120.0100.07718.24
5.6.110.0130.05018.27
5.6.100.0200.06718.18
5.6.90.0070.08718.13
5.6.80.0070.06317.67
5.6.70.0100.07717.56
5.6.60.0070.06717.52
5.6.50.0100.06317.61
5.6.40.0070.08017.51
5.6.30.0070.07317.63
5.6.20.0100.06017.52
5.6.10.0030.04317.50
5.6.00.0170.06717.63
5.5.350.0430.06320.53
5.5.340.0000.04317.98
5.5.330.0070.07017.99
5.5.320.0130.07317.95
5.5.310.0100.07717.98
5.5.300.0170.03017.92
5.5.290.0030.08017.98
5.5.280.0030.08017.98
5.5.270.0100.07717.90
5.5.260.0230.07017.99
5.5.250.0070.05017.85
5.5.240.0100.04317.40
5.5.230.0130.07017.31
5.5.220.0170.04317.46
5.5.210.0100.03717.46
5.5.200.0030.08017.43
5.5.190.0070.05017.34
5.5.180.0100.06717.32
5.5.160.0130.04317.39
5.5.150.0030.04717.33
5.5.140.0100.07317.30
5.5.130.0070.07017.45
5.5.120.0030.08017.34
5.5.110.0070.07317.31
5.5.100.0070.05317.24
5.5.90.0130.07317.34
5.5.80.0130.04017.24
5.5.70.0070.06017.21
5.5.60.0030.07317.32
5.5.50.0100.07717.19
5.5.40.0170.05017.23
5.5.30.0070.07317.32
5.5.20.0170.07017.17
5.5.10.0070.08017.30
5.5.00.0070.07317.27
5.4.450.0070.08319.32
5.4.440.0000.08719.34
5.4.430.0100.06719.33
5.4.420.0100.07319.37
5.4.410.0070.08019.18
5.4.400.0070.08019.02
5.4.390.0070.05319.10
5.4.380.0030.05319.05
5.4.370.0100.07319.04
5.4.360.0070.05019.09
5.4.350.0100.07319.10
5.4.340.0100.04319.05
5.4.320.0000.08019.11
5.4.310.0130.05019.03
5.4.300.0070.05719.13
5.4.290.0070.04318.98
5.4.280.0130.06719.01
5.4.270.0070.05718.95
5.4.260.0030.07018.98
5.4.250.0030.06319.05
5.4.240.0130.07018.97
5.4.230.0130.06319.27
5.4.220.0070.07319.26
5.4.210.0100.07719.04
5.4.200.0100.04319.12
5.4.190.0030.04718.88
5.4.180.0000.08019.13
5.4.170.0070.07719.04
5.4.160.0070.06319.11
5.4.150.0070.07718.87
5.4.140.0130.05716.48
5.4.130.0070.04016.43
5.4.120.0100.06716.42
5.4.110.0000.04016.64
5.4.100.0000.04016.43
5.4.90.0070.07016.40
5.4.80.0100.06716.44
5.4.70.0000.05316.58
5.4.60.0030.04016.32
5.4.50.0000.04316.32
5.4.40.0070.05716.58
5.4.30.0070.05316.38
5.4.20.0100.06016.42
5.4.10.0100.07016.40
5.4.00.0100.03315.75
5.3.290.0100.07714.79
5.3.280.0030.04314.60
5.3.270.0170.06714.62
5.3.260.0030.08314.68
5.3.250.0000.04014.69
5.3.240.0070.07314.57
5.3.230.0030.07714.66
5.3.220.0130.07014.64
5.3.210.0030.06714.66
5.3.200.0030.07714.53
5.3.190.0030.05014.61
5.3.180.0070.03314.58
5.3.170.0070.03714.53
5.3.160.0030.07714.59
5.3.150.0070.04014.42
5.3.140.0030.06014.62
5.3.130.0070.04014.59
5.3.120.0030.03714.53
5.3.110.0030.05314.58
5.3.100.0200.05314.12
5.3.90.0170.04014.09
5.3.80.0070.04014.07
5.3.70.0030.04013.91
5.3.60.0030.04013.85
5.3.50.0000.07313.85
5.3.40.0070.06014.00
5.3.30.0070.06313.93
5.3.20.0130.06713.73
5.3.10.0200.05713.70
5.3.00.0070.04013.71
5.2.170.0070.06311.22
5.2.160.0070.06011.16
5.2.150.0100.06011.20
5.2.140.0070.06011.22
5.2.130.0030.06711.21
5.2.120.0070.04011.01
5.2.110.0070.05711.15
5.2.100.0030.06711.16
5.2.90.0100.03011.10
5.2.80.0070.03011.18
5.2.70.0030.06011.14
5.2.60.0000.06711.05
5.2.50.0070.03010.93
5.2.40.0000.03011.02
5.2.30.0070.02711.03
5.2.20.0070.06011.07
5.2.10.0100.03710.88
5.2.00.0000.04010.63
5.1.60.0000.05010.22
5.1.50.0100.05010.22
5.1.40.0030.04010.00
5.1.30.0030.04710.39
5.1.20.0030.05710.38
5.1.10.0170.04010.12
5.1.00.0070.0309.93
5.0.50.0030.0479.07
5.0.40.0000.0209.07
5.0.30.0000.0409.07
5.0.20.0030.0279.07
5.0.10.0070.0439.07
5.0.00.0000.0679.07
4.4.90.0000.0309.07
4.4.80.0000.0239.07
4.4.70.0000.0239.07
4.4.60.0000.0379.07
4.4.50.0000.0309.07
4.4.40.0000.0379.07
4.4.30.0000.0309.07
4.4.20.0070.0339.07
4.4.10.0030.0339.07
4.4.00.0000.0409.07
4.3.110.0000.0239.07
4.3.100.0030.0309.07
4.3.90.0070.0309.07
4.3.80.0130.0409.07
4.3.70.0030.0379.07
4.3.60.0000.0209.07
4.3.50.0100.0239.07
4.3.40.0000.0539.07
4.3.30.0070.0339.07
4.3.20.0030.0239.07
4.3.10.0000.0279.07
4.3.00.0000.0379.07

preferences:
67.74 ms | 401 KiB | 5 Q