3v4l.org

run code in 300+ PHP versions simultaneously
<?php // index.php //require(baseController.php); //require(basemodel.php); //require(header.php); // baseController.php class baseController { function __construct($s) { echo "baseController says ". $s; } function speak($s) { } function look($l) { echo $l; } //function echoView($view) { //$this->view->render('views/header');// go to view controller and use the render method to echo view.php view. //} } // basemodel.php class baseModel { function __construct() { // acces db with new db(); } //public function userList($i) { //$query = $this->db->prepare('SELECET....'); //$query->execute(); //return $query->fetchAll(); //} } //view.php //<p>This is a view!</p> //header.php //<header></header> // controller methods operate models // userController.php class userController extends baseController { function __construct($s) { parent::__construct($s); } //function edit() { // $tis->view->user = $this->model->userList(); // $this->view->render(user/edit); //} } // model methods operate on the database // usermodel.php class userModel extends baseModel{ function __construct() { parent::__construct(); } public function userList() { $query = $this->db->prepare('SELECET users FROM...'); $query->execute(); return $query->fetchAll(); } } //$home = new baseController("Im in the base"); $home = new userController("Im just a user","and shows you it!");

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.00716.50
8.3.50.0120.00318.16
8.3.40.0070.00718.57
8.3.30.0100.00318.82
8.3.20.0040.00420.33
8.3.10.0060.00323.48
8.3.00.0040.00419.15
8.2.180.0090.00618.41
8.2.170.0100.00722.96
8.2.160.0100.00720.57
8.2.150.0030.00524.18
8.2.140.0090.00024.66
8.2.130.0050.00526.16
8.2.120.0000.00722.27
8.2.110.0090.00022.14
8.2.100.0090.00317.78
8.2.90.0000.00819.23
8.2.80.0000.00818.03
8.2.70.0080.00017.46
8.2.60.0050.00317.93
8.2.50.0000.00918.07
8.2.40.0030.00618.09
8.2.30.0080.00018.13
8.2.20.0000.00717.74
8.2.10.0030.00618.06
8.2.00.0000.00817.59
8.1.270.0000.00823.88
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0090.00023.84
8.1.230.0030.00719.16
8.1.220.0000.00717.74
8.1.210.0040.00418.77
8.1.200.0060.00317.22
8.1.190.0080.00017.30
8.1.180.0000.01018.88
8.1.170.0080.00018.51
8.1.160.0040.00421.83
8.1.150.0070.00018.46
8.1.140.0070.00017.44
8.1.130.0070.00017.85
8.1.120.0000.00717.40
8.1.110.0000.00817.38
8.1.100.0040.00417.29
8.1.90.0070.00017.43
8.1.80.0030.00617.44
8.1.70.0030.00317.34
8.1.60.0060.00317.64
8.1.50.0050.00317.45
8.1.40.0040.00417.54
8.1.30.0000.00817.63
8.1.20.0000.00717.66
8.1.10.0040.00417.57
8.1.00.0030.00517.50
8.0.300.0040.00418.83
8.0.290.0000.00717.18
8.0.280.0030.00318.45
8.0.270.0000.00717.33
8.0.260.0060.00017.25
8.0.250.0030.00316.96
8.0.240.0000.00617.01
8.0.230.0050.00216.84
8.0.220.0000.00816.82
8.0.210.0070.00016.80
8.0.200.0000.00616.98
8.0.190.0040.00416.79
8.0.180.0000.00716.75
8.0.170.0040.00416.96
8.0.160.0000.00816.84
8.0.150.0000.00816.72
8.0.140.0070.00016.86
8.0.130.0000.00513.26
8.0.120.0040.00416.77
8.0.110.0050.00316.91
8.0.100.0020.00516.79
8.0.90.0040.00416.86
8.0.80.0110.00316.77
8.0.70.0030.00316.90
8.0.60.0050.00216.95
8.0.50.0030.00516.81
8.0.30.0130.00817.30
8.0.20.0140.00517.40
8.0.10.0040.00417.00
8.0.00.0070.01016.84
7.4.330.0020.00215.00
7.4.320.0060.00016.52
7.4.300.0060.00016.56
7.4.290.0000.00716.52
7.4.280.0070.00016.48
7.4.270.0030.00316.62
7.4.260.0000.00716.45
7.4.250.0030.00516.47
7.4.240.0020.00516.58
7.4.230.0000.00716.71
7.4.220.0120.00616.68
7.4.210.0100.00516.60
7.4.200.0030.00616.63
7.4.190.0000.00816.46
7.4.160.0040.01916.43
7.4.150.0140.00317.40
7.4.140.0100.01217.86
7.4.130.0070.01016.49
7.4.120.0090.00816.52
7.4.110.0040.01516.29
7.4.100.0130.01016.50
7.4.90.0060.01116.67
7.4.80.0160.00719.39
7.4.70.0120.00416.55
7.4.60.0040.01216.29
7.4.50.0060.00316.27
7.4.40.0030.00922.77
7.4.30.0090.00916.69
7.4.10.0000.01916.49
7.4.00.0110.00515.70
7.3.330.0070.00013.11
7.3.320.0000.00513.11
7.3.310.0030.00316.30
7.3.300.0030.00316.28
7.3.290.0070.01016.21
7.3.280.0100.01216.23
7.3.270.0200.00417.40
7.3.260.0060.01216.35
7.3.250.0070.01016.37
7.3.240.0130.00916.47
7.3.230.0120.00916.39
7.3.210.0140.00316.29
7.3.200.0130.01019.39
7.3.190.0070.01016.37
7.3.180.0100.00616.18
7.3.170.0060.00916.27
7.3.160.0090.00716.42
7.3.130.0130.00316.55
7.3.120.0110.00415.51
7.3.110.0060.01016.06
7.3.100.0030.00916.21
7.3.90.0060.00616.32
7.3.80.0000.01216.13
7.3.70.0040.01116.32
7.3.60.0040.00716.25
7.3.50.0070.00716.43
7.3.40.0040.01216.22
7.3.30.0070.00716.23
7.3.20.0030.01018.22
7.3.10.0090.00618.28
7.3.00.0030.01518.11
7.2.330.0090.00916.44
7.2.320.0130.01016.44
7.2.310.0060.01116.79
7.2.300.0080.00816.80
7.2.290.0130.00316.38
7.2.260.0030.01716.64
7.2.250.0100.01016.33
7.2.240.0000.01516.72
7.2.230.0060.00916.70
7.2.220.0040.01116.66
7.2.210.0070.01016.44
7.2.200.0130.00316.64
7.2.190.0100.00616.59
7.2.180.0040.01216.53
7.2.170.0030.01416.49
7.2.160.0120.00616.63
7.2.150.0060.01318.38
7.2.140.0030.01318.31
7.2.130.0030.01618.34
7.2.120.0070.01418.35
7.2.110.0030.01018.25
7.2.100.0110.00718.33
7.2.90.0120.00318.33
7.2.80.0040.01518.38
7.2.70.0060.01018.18
7.2.60.0040.00818.20
7.2.50.0060.00918.40
7.2.40.0040.01518.44
7.2.30.0000.01418.41
7.2.20.0060.00918.40
7.2.10.0080.00318.32
7.2.00.0060.00718.87
7.1.330.0030.01017.24
7.1.320.0070.00717.08
7.1.310.0070.00317.34
7.1.300.0000.01417.15
7.1.290.0090.00317.34
7.1.280.0060.00617.20
7.1.270.0060.01317.34
7.1.260.0030.00917.43
7.1.250.0030.01017.45
7.1.240.0070.01117.21
7.1.230.0070.00717.23
7.1.220.0080.00817.23
7.1.210.0090.00317.42
7.1.200.0060.01317.24
7.1.190.0030.01017.31
7.1.180.0120.00017.11
7.1.170.0060.00917.30
7.1.160.0150.00017.20
7.1.150.0070.01017.26
7.1.140.0100.00317.38
7.1.130.0030.00817.35
7.1.120.0060.00917.20
7.1.110.0070.00717.27
7.1.100.0040.00917.63
7.1.90.0060.00617.30
7.1.80.0060.00617.19
7.1.70.0050.00917.03
7.1.60.0080.00818.46
7.1.50.0050.01416.88
7.1.40.0040.01117.28
7.1.30.0050.00517.20
7.1.20.0000.01217.18
7.1.10.0000.01317.27
7.1.00.0030.04419.79
7.0.330.0030.01717.08
7.0.320.0060.00316.92
7.0.310.0090.01216.97
7.0.300.0040.00817.15
7.0.290.0070.00716.90
7.0.280.0030.01316.94
7.0.270.0060.00617.05
7.0.260.0060.00316.88
7.0.250.0040.00717.32
7.0.240.0040.01117.15
7.0.230.0000.01217.13
7.0.220.0090.00617.13
7.0.210.0060.00617.13
7.0.200.0020.00916.85
7.0.190.0030.01416.88
7.0.180.0040.00417.20
7.0.170.0070.00417.09
7.0.160.0000.01217.07
7.0.150.0090.00616.89
7.0.140.0000.04319.67
7.0.130.0060.00617.14
7.0.120.0090.00617.02
7.0.110.0000.00917.00
7.0.100.0050.00517.03
7.0.90.0000.01416.79
7.0.80.0070.00716.89
7.0.70.0030.01316.84
7.0.60.0050.04518.50
7.0.50.0080.04317.38
7.0.40.0070.04717.61
7.0.30.0250.03617.60
7.0.20.0250.02517.51
7.0.10.0080.04517.60
7.0.00.0060.04517.49
5.6.400.0040.00416.04
5.6.390.0160.00315.96
5.6.380.0090.00616.00
5.6.370.0100.01015.67
5.6.360.0110.00416.04
5.6.350.0060.00315.98
5.6.340.0090.00616.06
5.6.330.0040.00715.98
5.6.320.0090.00615.80
5.6.310.0000.01316.00
5.6.300.0030.00916.01
5.6.290.0070.00415.96
5.6.280.0050.04018.41
5.6.270.0060.01015.71
5.6.260.0120.00615.82
5.6.250.0060.00615.77
5.6.240.0040.01215.84
5.6.230.0030.01615.97
5.6.220.0030.00616.00
5.6.210.0110.02518.14
5.6.200.0040.03316.99
5.6.190.0090.02218.24
5.6.180.0130.02518.02
5.6.170.0230.02918.23
5.6.160.0050.04518.30
5.6.150.0030.04517.05
5.6.140.0050.02416.99
5.6.130.0020.03917.03
5.6.120.0070.03018.51
5.6.110.0050.04618.41
5.6.100.0030.02618.35
5.6.90.0110.04018.35
5.6.80.0030.04418.08
5.6.70.0030.01015.73
5.6.60.0080.00315.85
5.6.50.0060.00615.64
5.6.40.0070.01015.68
5.6.30.0080.00615.91
5.6.20.0100.00615.71
5.6.10.0040.01115.67
5.6.00.0030.00615.71
5.5.380.0060.01015.71
5.5.370.0060.00915.92
5.5.360.0060.00915.64
5.5.350.0030.04318.04
5.5.340.0070.04617.01
5.5.330.0100.04218.06
5.5.320.0230.01818.23
5.5.310.0150.03918.13
5.5.300.0030.04216.88
5.5.290.0070.02016.87
5.5.280.0050.03818.29
5.5.270.0170.03018.29
5.5.260.0130.03818.35
5.5.250.0060.04518.11
5.5.240.1900.02717.89
5.5.230.0060.00315.83
5.5.220.0030.01515.73
5.5.210.0100.00315.75
5.5.200.0090.00015.89
5.5.190.0150.00315.45
5.5.180.0110.00315.81
5.5.170.0060.00915.84
5.5.160.0030.01015.92
5.5.150.0060.00915.84
5.5.140.0090.00615.85
5.5.130.0040.01015.80
5.5.120.0110.00415.85
5.5.110.0040.01115.54
5.5.100.0100.00715.75
5.5.90.0030.01215.79
5.5.80.0090.00915.79
5.5.70.0040.00815.64
5.5.60.0040.01115.46
5.5.50.0070.00415.57
5.5.40.0030.00615.79
5.5.30.0060.00315.69
5.5.20.0030.00615.84
5.5.10.0070.00715.67
5.5.00.0060.00815.67
5.4.450.0260.03516.15
5.4.440.0400.02916.15
5.4.430.0050.03216.14
5.4.420.0100.02816.10
5.4.410.0120.02716.17
5.4.400.0070.03315.88
5.4.390.0080.02815.93
5.4.380.0150.02815.68
5.4.370.0150.03315.76
5.4.360.0150.02515.60
5.4.350.0200.03715.74
5.4.340.0150.03315.74
5.4.330.0000.00712.73
5.4.320.0060.02512.62
5.4.310.0060.02612.68
5.4.300.0100.02612.62
5.4.290.0030.02412.62
5.4.280.0050.03312.55
5.4.270.0100.02912.55
5.4.260.0070.02612.55
5.4.250.0040.02512.55
5.4.240.0080.01912.60
5.4.230.0030.02812.55
5.4.220.0070.02312.55
5.4.210.0070.03112.55
5.4.200.0050.02412.57
5.4.190.0060.02012.55
5.4.180.0060.01912.54
5.4.170.0070.01912.55
5.4.160.0070.01812.55
5.4.150.0060.02212.61
5.4.140.0060.02412.48
5.4.130.0110.01812.38
5.4.120.0040.02212.36
5.4.110.0070.02712.36
5.4.100.0050.02012.36
5.4.90.0030.02312.36
5.4.80.0080.02312.36
5.4.70.0050.01912.36
5.4.60.0080.01912.36
5.4.50.0050.02412.36
5.4.40.0070.02012.35
5.4.30.0090.01912.35
5.4.20.0060.02212.38
5.4.10.0040.03012.35
5.4.00.0030.02412.10
5.3.290.0070.02712.90
5.3.280.0040.02812.79
5.3.270.0090.02212.82
5.3.260.0070.02512.89
5.3.250.0100.02412.93
5.3.240.0060.03012.87
5.3.230.0080.03212.79
5.3.220.0040.03212.77
5.3.210.0080.02312.81
5.3.200.0080.01912.92
5.3.190.0070.02312.94
5.3.180.0040.02612.90
5.3.170.0050.02312.85
5.3.160.0060.02512.85
5.3.150.0070.02312.87
5.3.140.0070.02212.83
5.3.130.0090.02012.79
5.3.120.0070.02412.79
5.3.110.0050.02112.78
5.3.100.0050.02612.67
5.3.90.0040.02512.60
5.3.80.0040.02212.49
5.3.70.0030.02512.64
5.3.60.0070.02012.54
5.3.50.0080.02212.48
5.3.40.0090.02112.51
5.3.30.0070.02112.49
5.3.20.0070.02112.38
5.3.10.0050.02212.23
5.3.00.0070.01912.29
5.2.170.0050.0319.20
5.2.160.0030.0349.20
5.2.150.0090.0289.21
5.2.140.0040.0349.20
5.2.130.0060.0299.16
5.2.120.0090.0309.16
5.2.110.0090.0279.17
5.2.100.0040.0379.16
5.2.90.0100.0369.16
5.2.80.0040.0459.16
5.2.70.0060.0349.15
5.2.60.0090.0349.11
5.2.50.0050.0309.09
5.2.40.0100.0349.06
5.2.30.0060.0379.04
5.2.20.0060.0329.02
5.2.10.0080.0398.93
5.2.00.0100.0288.79
5.1.60.0120.0278.09
5.1.50.0060.0318.09
5.1.40.0080.0278.06
5.1.30.0070.0328.40
5.1.20.0070.0328.43
5.1.10.0040.0308.16
5.1.00.0050.0258.16
5.0.50.0040.0216.63
5.0.40.0030.0226.50
5.0.30.0050.0306.31
5.0.20.0050.0186.27
5.0.10.0050.0186.25
5.0.00.0040.0306.24
4.4.90.0040.0144.78
4.4.80.0060.0194.76
4.4.70.0060.0164.75
4.4.60.0030.0174.75
4.4.50.0040.0164.77
4.4.40.0030.0264.71
4.4.30.0020.0174.76
4.4.20.0020.0184.84
4.4.10.0020.0204.85
4.4.00.0040.0304.76
4.3.110.0050.0174.67
4.3.100.0040.0144.66
4.3.90.0050.0134.63
4.3.80.0020.0254.59
4.3.70.0030.0144.63
4.3.60.0030.0144.63
4.3.50.0060.0124.62
4.3.40.0020.0244.54
4.3.30.0020.0163.30
4.3.20.0050.0143.28
4.3.10.0020.0173.24
4.3.00.0100.0208.61

preferences:
56.7 ms | 400 KiB | 5 Q