Hi Juliette,
> Hi Saki,
>
> Just wondering: why int|string
instead of float|string
?
> In my experience, floats are the more pertinent type for which to use the BCMath extension.
>
> Smile,
> Juliette
Since floating point numbers always contain a certain amount of error, I believe that they are not
suitable as arguments for BCMath.
For example, 0.285 becomes 0.284999... in floating point. From the perspective of arbitrary
precision math, there is no universally agreeable way to properly handle values like this:
there will always be people who want to treat it as 0.285, and people who want to treat it as
0.284999....
Therefore, I believe BCMath should not accept floats as arguments.
Regards,
Saki