SDP2006
09-18-2003, 09:42 PM
Any good tutorials on doing basic math in PHP?
i.e. 9*7, 8/68, 2+2, 4-2, etc. etc.
Thanks
i.e. 9*7, 8/68, 2+2, 4-2, etc. etc.
Thanks
|
||||
Mathematics and PHPSDP2006 09-18-2003, 09:42 PM Any good tutorials on doing basic math in PHP? i.e. 9*7, 8/68, 2+2, 4-2, etc. etc. Thanks mordred 09-18-2003, 09:47 PM Just put it in a expression and execute it: print 6 * 7; Or did you have something different in mind? SDP2006 09-18-2003, 09:48 PM Okay, sorry for posting, found it in the PHP Manual right after I posted. Thanks mordred :) Acecool 09-19-2003, 02:46 AM <?php $something = (89234 * 2382378 + 24 / 10); echo $something; ?> bored 09-23-2003, 09:41 PM For continuity sake, try seperating your arguments for calculation. Good for debugging as well. <?php $something = ((89234 * 2382378) + (24 / 10)); echo $something; ?> |
| |||
EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum