3v4l.org

run code in 300+ PHP versions simultaneously
<?php $bmi = sprintf("%.2lf", calculateBMI($height, $heightUnit, $weight, $weightUnit)); $text = //"<p> "."<img src = ". //" http://cs.smu.ca/~webbook/cdrom/web08/nature/images/naturelogo.gif ". //" alt = 'Nature's Source Logo' />"."</p>". "<h1>BMI Report</h1>". "<h3>Your height: ".$height." ".$heightUnit."<br />". "Your weight: ".$weight." ".$weightUnit."<br />". "Your BMI: ".$bmi."</h3>"; if ($bmi < 18.5) $text .= "<h2>Your BMI suggests that you are underweight.</h2>"; else if ($bmi < 25) $text .= "<h2>Your BMI suggests that you have a reasonable weight.</h2>"; else if ($bmi < 29) $text .= "<h2>Your BMI suggests that you are overweight.</h2>"; else $text .= "<h2>Your BMI suggests that you may be obese.</h2>"; return $text;

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.40.0120.00418.64
8.3.30.0080.00818.59
8.3.20.0050.00220.25
8.3.10.0030.00621.76
8.3.00.0000.00819.67
8.2.170.0130.00622.96
8.2.160.0000.01320.52
8.2.150.0030.00524.18
8.2.140.0150.00324.66
8.2.130.0070.00026.16
8.2.120.0060.00317.50
8.2.110.0030.00622.16
8.2.100.0050.00517.72
8.2.90.0040.00419.28
8.2.80.0050.00517.97
8.2.70.0040.00417.50
8.2.60.0000.00917.80
8.2.50.0050.00518.07
8.2.40.0030.00521.11
8.2.30.0040.00418.04
8.2.20.0050.00317.72
8.2.10.0030.00518.14
8.2.00.0000.00718.02
8.1.270.0030.00620.27
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0050.00519.00
8.1.230.0040.00717.52
8.1.220.0040.00417.74
8.1.210.0060.00318.77
8.1.200.0000.01217.23
8.1.190.0040.00417.10
8.1.180.0000.00718.10
8.1.170.0050.00318.51
8.1.160.0040.00422.04
8.1.150.0000.00718.70
8.1.140.0040.00417.40
8.1.130.0000.00717.62
8.1.120.0000.00717.29
8.1.110.0050.00317.28
8.1.100.0000.00917.38
8.1.90.0070.00017.38
8.1.80.0050.00217.41
8.1.70.0000.00717.31
8.1.60.0040.00417.45
8.1.50.0090.00017.37
8.1.40.0060.00317.43
8.1.30.0000.00817.55
8.1.20.0050.00317.48
8.1.10.0060.00317.57
8.1.00.0060.00317.37
8.0.300.0000.00718.77
8.0.290.0050.00316.63
8.0.280.0040.00418.33
8.0.270.0000.00817.15
8.0.260.0050.00217.23
8.0.250.0040.00416.87
8.0.240.0030.00516.88
8.0.230.0040.00417.02
8.0.220.0000.00716.82
8.0.210.0000.00916.93
8.0.200.0060.00016.98
8.0.190.0070.00016.89
8.0.180.0070.00016.90
8.0.170.0040.00416.96
8.0.160.0000.00816.86
8.0.150.0040.00416.75
8.0.140.0000.00716.79
8.0.130.0000.00513.28
8.0.120.0050.00316.92
8.0.110.0000.00716.97
8.0.100.0040.00417.04
8.0.90.0030.00516.96
8.0.80.0190.00316.85
8.0.70.0070.00016.90
8.0.60.0040.00416.76
8.0.50.0040.00416.89
8.0.30.0090.01117.02
8.0.20.0080.01117.40
8.0.10.0020.00517.03
8.0.00.0110.00716.63
7.4.330.0070.00015.08
7.4.320.0040.00416.34
7.4.300.0030.00316.46
7.4.290.0040.00416.44
7.4.280.0090.00016.37
7.4.270.0000.00716.47
7.4.260.0070.00016.52
7.4.250.0050.00316.52
7.4.240.0050.00216.51
7.4.230.0030.00316.46
7.4.220.0100.00716.50
7.4.210.0040.01116.51
7.4.200.0040.00416.50
7.4.160.0100.01316.35
7.4.150.0070.01017.40
7.4.140.0150.01017.86
7.4.130.0080.01016.63
7.4.120.0100.00716.38
7.4.110.0100.00716.59
7.4.100.0120.00916.48
7.4.90.0070.01016.47
7.4.80.0070.01019.39
7.4.70.0070.01016.54
7.4.60.0080.01116.37
7.4.50.0000.00816.17
7.4.40.0030.01316.49
7.4.30.0070.01016.52
7.4.00.0100.00614.92
7.3.330.0000.00513.14
7.3.320.0000.00513.28
7.3.310.0000.00616.33
7.3.300.0000.00816.29
7.3.290.0050.01216.28
7.3.280.0100.01116.32
7.3.270.0170.00317.40
7.3.260.0030.01416.54
7.3.250.0080.01016.47
7.3.240.0170.00716.33
7.3.230.0110.00616.42
7.3.210.0100.00616.22
7.3.200.0060.01016.23
7.3.190.0060.01016.59
7.3.180.0100.01016.34
7.3.170.0070.01016.50
7.3.160.0090.00916.40
7.2.330.0090.00916.51
7.2.320.0130.01016.53
7.2.310.0130.00616.14
7.2.300.0070.01416.16
7.2.290.0060.01216.53
7.2.110.0430.00416.57
7.2.100.0110.01116.53
7.2.90.0090.00616.44
7.2.80.0120.00616.25
7.2.70.0120.00416.84
7.2.60.0090.00716.72
7.2.50.0140.00716.57
7.2.40.0180.00416.82
7.2.30.0520.00716.61
7.2.20.0490.00216.55
7.2.10.0160.00316.73
7.2.00.0040.01418.05
7.1.230.0090.00915.75
7.1.220.0110.00415.41
7.1.210.0110.00315.64
7.1.200.1340.00915.66
7.1.190.0120.00315.55
7.1.180.0480.00715.58
7.1.170.0100.00515.53
7.1.160.0180.00015.30
7.1.150.0190.00415.63
7.1.140.0110.00615.63
7.1.130.0100.00715.27
7.1.120.0100.00515.37
7.1.110.0360.00315.52
7.1.100.0180.00716.73
7.1.90.0100.00615.56
7.1.80.0090.00315.73
7.1.70.0060.00616.24
7.1.60.0080.01217.97
7.1.50.0070.01616.10
7.1.40.0130.00715.56
7.1.30.0050.01415.65
7.1.20.0120.00915.94
7.1.10.0120.00315.62
7.1.00.0120.03319.01
7.0.310.0090.00614.99
7.0.300.0100.00715.28
7.0.290.0100.01015.00
7.0.280.0140.00315.32
7.0.270.0340.00615.47
7.0.260.0160.00315.31
7.0.250.0040.00815.50
7.0.240.0030.01015.34
7.0.230.0410.00015.17
7.0.220.0090.00315.42
7.0.210.0140.00015.39
7.0.200.0190.00515.02
7.0.190.0110.00615.34
7.0.180.0120.00415.30
7.0.170.0120.00015.48
7.0.160.0620.00015.48
7.0.150.0150.00015.24
7.0.140.0140.00015.30
7.0.130.0650.00015.31
7.0.120.0150.00015.09
7.0.110.0160.00015.11
7.0.100.0890.00315.23
7.0.90.0080.00815.52
7.0.80.0080.00814.98
7.0.70.0120.00915.21
7.0.60.0080.04317.65
7.0.50.0100.02616.67
7.0.40.0100.02216.74
7.0.30.0150.02416.76
7.0.20.0210.03916.64
7.0.10.0090.02216.80
7.0.00.0080.04516.69
5.6.380.0090.00513.91
5.6.370.0100.00314.01
5.6.360.0070.00714.26
5.6.350.0090.00614.36
5.6.340.0100.00713.78
5.6.330.0150.00314.05
5.6.320.0170.00014.08
5.6.310.0100.00713.66
5.6.300.0050.00814.20
5.6.290.0110.00513.98
5.6.280.0020.02217.72
5.6.270.0110.01114.27
5.6.260.0120.00313.99
5.6.250.0110.00614.16
5.6.240.0110.00314.16
5.6.230.0050.00914.15
5.6.220.0070.01014.14
5.6.210.0150.03217.48
5.6.200.0060.03916.16
5.6.190.0110.04217.33
5.6.180.0150.02617.22
5.6.170.0180.02817.13
5.6.160.0100.04217.33
5.6.150.0130.03516.10
5.6.140.0080.02516.19
5.6.130.0100.04416.10
5.6.120.0080.04317.59
5.6.110.0130.02817.54
5.6.100.0150.04017.67
5.6.90.0120.02817.44
5.6.80.0050.03917.25
5.6.70.1410.02717.22
5.6.60.0110.00514.16
5.6.50.0060.00914.18
5.6.40.0080.00814.10
5.6.30.0100.00713.96
5.6.20.0120.00413.95
5.6.10.0080.00513.97
5.6.00.0110.00514.17
5.5.380.0070.00712.79
5.5.370.0090.00712.79
5.5.360.0120.00412.79
5.5.350.0100.04016.59
5.5.340.0070.04315.35
5.5.330.0100.04216.46
5.5.320.0230.02116.55
5.5.310.0220.04116.64
5.5.300.0140.03915.36
5.5.290.0050.03115.35
5.5.280.0120.04016.83
5.5.270.0060.03916.86
5.5.260.0150.04016.79
5.5.250.0140.02616.72
5.5.240.0040.03716.49
5.5.230.0130.00312.79
5.5.220.0070.00712.79
5.5.210.0110.00412.79
5.5.200.0090.00312.79
5.5.190.0040.00712.79
5.5.180.0070.00412.79
5.5.170.0150.00313.80
5.5.160.0100.00312.79
5.5.150.0120.00012.79
5.5.140.0070.00412.79
5.5.130.0090.00612.79
5.5.120.0110.00312.79
5.5.110.0110.00412.79
5.5.100.0060.00612.79
5.5.90.0130.00012.79
5.5.80.0100.00412.79
5.5.70.0140.00012.79
5.5.60.0100.00312.79
5.5.50.0100.00312.79
5.5.40.0070.00712.79
5.5.30.0100.00312.79
5.5.20.0040.00712.79
5.5.10.0080.00412.79
5.5.00.0100.00312.79
5.4.450.0140.02715.90
5.4.440.0140.03116.12
5.4.430.0100.03016.04
5.4.420.0020.03516.02
5.4.410.0310.02815.96
5.4.400.0400.03215.87
5.4.390.0350.02415.74
5.4.380.0130.03215.96
5.4.370.0300.03015.97
5.4.360.0090.03015.74
5.4.350.0250.03015.74
5.4.340.0210.02215.97
5.4.330.0130.00012.79
5.4.320.0160.02615.97
5.4.310.0120.02615.95
5.4.300.0080.02815.97
5.4.290.0110.02915.97
5.4.280.0120.03415.94
5.4.270.0080.03115.92
5.4.260.0160.03015.87
5.4.250.0220.02115.96
5.4.240.0170.02715.76
5.4.230.0160.02815.86
5.4.220.0170.02515.87
5.4.210.0140.02715.94
5.4.200.0120.02815.73
5.4.190.0110.02815.93
5.4.180.0170.02415.73
5.4.170.0190.02615.96
5.4.160.0110.03015.91
5.4.150.0160.02615.91
5.4.140.0160.02414.51
5.4.130.0090.03014.59
5.4.120.0080.03114.59
5.4.110.0130.02514.63
5.4.100.0100.02914.56
5.4.90.0180.02514.60
5.4.80.0140.02514.56
5.4.70.0190.02514.61
5.4.60.0190.03314.49
5.4.50.0070.03314.57
5.4.40.0080.02914.61
5.4.30.0050.02614.57
5.4.20.0030.04314.58
5.4.10.0090.00412.79
5.4.00.0070.00312.79

preferences:
52.09 ms | 400 KiB | 5 Q