|
Posted by groups2 on 12/31/07 20:55
On Dec 31, 2:40 pm, Justin Koivisto <justin.koivi...@gmail.com> wrote:
> grou...@reenie.org wrote:
> > This is true: "2-3"==1
>
> > But "1-2"==1 is not true
>
> > Why ?
>
> <?php
> var_dump("2-3"==1);
> var_dump("1-2"==1);
> ?>
> Output:
> bool(false)
> bool(true)
>
> Why? "2-3" evaluates to 2, "1-2" evaluates to 1. 2!=1 therefore the
> first statement is false, the second one is true because 1==1
>
> --
> Posted via a free Usenet account fromhttp://www.teranews.com
OK, thanks, it makes sense now.
[Back to original message]
|