3v4l.org

run code in 300+ PHP versions simultaneously
<?php $tests = [ "7.2769482308e+01", "3.43E-6", "2.54E-14", "99.87E-2" ]; foreach($tests as $test){ echo $test, " => ", getFormattedDecimal($test),PHP_EOL; } function getFormattedDecimal($str){ $precision = explode("e", strtolower($str)); $precision = substr($precision[1], 1); // remove + and - operators return sprintf("%.".$precision."f", $str); }

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.4.120.0100.00922.50
8.4.110.0090.01122.41
8.4.100.0100.01117.64
8.4.90.0120.01018.66
8.4.80.0080.00417.91
8.4.70.0100.01017.98
8.4.60.0110.01018.71
8.4.50.0080.00217.95
8.4.40.0060.00317.56
8.4.30.0130.00620.38
8.4.20.0040.01824.21
8.4.10.0070.00324.08
8.3.250.0050.00418.95
8.3.240.0120.00816.66
8.3.230.0140.00516.82
8.3.220.0040.00417.30
8.3.210.0110.00516.63
8.3.200.0050.00416.53
8.3.190.0070.01218.94
8.3.180.0120.00716.60
8.3.170.0180.00019.00
8.3.160.0110.00716.60
8.3.150.0120.00617.20
8.3.140.0140.00016.36
8.3.130.0030.00618.41
8.3.120.0000.00918.96
8.3.110.0110.00420.94
8.3.100.0180.00024.06
8.3.90.0150.00426.77
8.3.80.0060.00618.18
8.3.70.0030.01216.63
8.3.60.0100.01016.63
8.3.50.0040.01116.80
8.3.40.0040.01119.96
8.3.30.0120.00618.85
8.3.20.0070.00024.18
8.3.10.0080.00024.66
8.3.00.0040.00426.16
8.2.290.0090.00920.47
8.2.280.0090.00918.57
8.2.270.0160.00416.43
8.2.260.0060.01119.05
8.2.250.0040.00419.00
8.2.240.0050.00517.22
8.2.230.0040.00422.58
8.2.220.0100.01037.54
8.2.210.0180.00026.77
8.2.200.0000.01116.75
8.2.190.0090.00616.75
8.2.180.0120.00318.29
8.2.170.0090.00618.79
8.2.160.0100.01022.96
8.2.150.0040.00425.66
8.2.140.0050.00324.66
8.2.130.0080.00026.16
8.2.120.0070.00020.81
8.2.110.0030.00621.12
8.2.100.0080.00417.59
8.2.90.0060.00318.03
8.2.80.0040.00417.97
8.2.70.0050.00317.75
8.2.60.0080.00017.63
8.2.50.0000.00817.63
8.2.40.0130.00317.62
8.2.30.0140.00017.62
8.2.20.0080.00817.62
8.2.10.0130.00317.62
8.2.00.0160.00017.63
8.1.330.0110.00722.11
8.1.320.0080.01216.34
8.1.310.0040.00416.58
8.1.300.0060.00318.50
8.1.290.0090.00030.84
8.1.280.0100.01025.92
8.1.270.0100.00320.40
8.1.260.0000.00926.35
8.1.250.0040.00428.09
8.1.240.0090.00022.44
8.1.230.0090.00320.95
8.1.220.0080.00017.78
8.1.210.0060.00318.77
8.1.200.0080.00017.35
8.1.190.0040.00417.35
8.1.180.0050.00318.10
8.1.170.0170.00017.62
8.1.160.0110.00517.62
8.1.150.0050.01117.62
8.1.140.0090.00617.62
8.1.130.0110.00417.62
8.1.120.0080.00817.62
8.1.110.0140.00217.62
8.1.100.0090.00917.62
8.1.90.0090.00917.62
8.1.80.0100.00717.62
8.1.70.0180.00017.62
8.1.60.0140.00417.62
8.1.50.0130.00417.62
8.1.40.0110.00617.62
8.1.30.0090.00917.62
8.1.20.0180.00017.62
8.1.10.0160.00617.62
8.1.00.0110.00617.62
8.0.300.0040.00419.90
8.0.290.0060.00316.75
8.0.280.0110.00617.62
8.0.270.0120.00317.62
8.0.260.0140.00317.62
8.0.250.0130.00417.62
8.0.240.0130.00517.62
8.0.230.0160.00317.62
8.0.220.0050.01117.62
8.0.210.0120.00417.62
8.0.200.0100.00717.62
8.0.190.0130.00317.62
8.0.180.0110.00617.62
8.0.170.0060.01017.62
8.0.160.0120.00417.62
8.0.150.0100.00717.62
8.0.140.0130.00317.62
8.0.130.0080.00817.62
8.0.120.0090.00917.62
8.0.110.0140.00317.62
8.0.100.0110.00617.62
8.0.90.0060.00917.62
8.0.80.0080.00817.62
8.0.70.0110.00517.62
8.0.60.0110.00617.62
8.0.50.0110.00617.62
8.0.30.0160.00317.62
8.0.20.0110.00617.62
8.0.10.0110.00517.62

preferences:
27.52 ms | 403 KiB | 5 Q