PHP 8.5.0 Alpha 1 available for testing

Voting

: min(nine, three)?
(Example: nine)

The Note You're Voting On

pfreet at gmail dot com
12 years ago
Do not use intval() when you really want round(). This is due to how PHP handles precision.

echo number_format(8.20*100, 20), "<br />";
echo intval(8.20*100), "<br />";
echo floor(8.20*100), "<br />";
echo round(8.20*100), "<br />";

819.99999999999988631316
819
819
820

<< Back to user notes page

To Top