On Tue, 2003-06-03 at 19:49, Chris Cameron wrote:
> I'm having a problem I don't think I should be having. Basically, I'm
> doing some simple math, and I'm having issues in making PHP do it (with
> the brackets in particular).
> 
> An example that looks like it -should- work:
> 
> $Math = sqrt(81)(5+4)-1;
> 
> Well of course that doesn't work because of the (I believe) brackets.
> I'm unable to think of any easy alternative that wouldn't make
> reading/writing these things terribly messy/hard.
> 
> The above examples I just pulled out of the air, but I need to deal with
> many groupings with brackets, various functions (pow() and sqrt()
> mostly) and basic addition and subtraction, which adds a greater
> complexity.
> 
> Have I missed something obvious? Or am I doomed to do a bunch of smaller
> math things so that I can do these bigger ones?

What is the relation between the sqrt(81) and the (5+4)-1? i.e. there
is no operator there...which operator *should* be there?


Torben

> Thanks,
> Chris
> 
> -- 
> Chris Cameron
> UpNIX Internet Administrator
> ardvark.upnix.net
> bitbucket.upnix.net
> --
> http://www.upnix.com

-- 
 Torben Wilson <[EMAIL PROTECTED]>                        +1.604.709.0506
 http://www.thebuttlesschaps.com          http://www.inflatableeye.com
 http://www.hybrid17.com                  http://www.themainonmain.com
 -----==== Boycott Starbucks!  http://www.haidabuckscafe.com ====-----




-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to