> -----Original Message----- > From: Lee Doolan [mailto:[EMAIL PROTECTED]] > Sent: 14 June 2002 01:25 > > >>>>> "Miguel" == Miguel Cruz <[EMAIL PROTECTED]> writes: > > Miguel> Why does this: > > Miguel> $x = 3 + 5 * 7; > > Miguel> produce different results from this: > > Miguel> $x = (3 + 5) * 7; > > Miguel> ? > > Miguel> miguel > > The two cases are not the same. In the case above, all operators are > ternary --with equal precedence-- but in your case, the operators are > of different precedence.
OK, try this: why does $x = 3 + 5 - 7; produce different results from $x = 3 + (5 - 7); Cheers! Mike --------------------------------------------------------------------- Mike Ford, Electronic Information Services Adviser, Learning Support Services, Learning & Information Services, JG125, James Graham Building, Leeds Metropolitan University, Beckett Park, LEEDS, LS6 3QS, United Kingdom Email: [EMAIL PROTECTED] Tel: +44 113 283 2600 extn 4730 Fax: +44 113 283 3211 -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php