On 4/16/07, Antony Dovgal <[EMAIL PROTECTED]> wrote:
On 04/15/2007 11:05 AM, Sebastian Nohn wrote:
> <?php
> $a = 6900000000;
> var_dump($a);
> $b = "A is: ".$a;
> var_dump($b);
> ?>
>
> 5.2.1 output is:
>
> float(6.9E+9)
> string(16) "A is: 6900000000"
>
> 5.2.2-dev output is:
>
> float(6.9E+9)
> string(12) "A is: 6.9E+9"

Nice catch, thanks.

What do you think is the most correct output for 1 000 000 000 000 000 (with 
precision = 14)?
Versions <= 5.2.1 output "1E+15", 5.2.2 says "1.0E+15".

Both options looks ok to me, but we need to decide which one is the best.
I can find pros/cons for both options myself and it doesn't matter for me which 
one is chosen, though somebody might.
I remember asking people on the channel and the most popular answer was "both are 
legal and look ok".

Opinions?

--
Wbr,
Antony Dovgal

The second one "1.0E+15" is more precise, as it has the extra 0. Other
than that there's no big difference between them. But because it was
in 5.2.1 and before, it might be better to choose the first one.

Tijnema

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php



--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to