You can set the precision used when formatting floats as strings using the precision
ini setting, the default being 14:
ini_set('precision', 16);echo $a - $b; // 1999999.99999999
Also, read this article for a more generic breakdown on the subject.
You can set the precision used when formatting floats as strings using the precision
ini setting, the default being 14:
ini_set('precision', 16);echo $a - $b; // 1999999.99999999
Also, read this article for a more generic breakdown on the subject.