Tricky things in PHP – floats
As Laravel developer we don’t deal only with Laravel specific features, but quite often with pure PHP. Let’s verify your knowledge a bit. What would be the result of the following script:
1 2 3 |
<?php die(var_dump(1200.85 * 100 === 120085)); |
Possible answers: false true It depends … Okay, you’ve chosen your answer. The second question – would the answer change if we … [Read more…]