note 108734 added to function.pow
| From: | chris at ocportal dot com | Date: | Mon, 21 May 2012 16:05:13 +0000 |
| Subject: | note 108734 added to function.pow | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-188108@lists.php.net to get a copy of this message | ||
Many notations use "^" as a power operator, but in PHP (and other C-based languages) that
is actually the XOR operator. You need to use this 'pow' function, there is no power
operator.
i.e. 3^2 means "3 XOR 2" not "3 squared".
It is particular confusing as when doing Pythagoras theorem in a 'closet points' algorithm
using "^" you get results that look vaguely correct but with an error.
----
Server IP: 69.147.83.197
Probable Submitter: 188.221.7.254
----
Manual Page -- http://www.php.net/manual/en/function.pow.php
Edit -- https://master.php.net/note/edit/108734
Del: integrated -- https://master.php.net/note/delete/108734/integrated
Del: useless -- https://master.php.net/note/delete/108734/useless
Del: bad code -- https://master.php.net/note/delete/108734/bad+code
Del: spam -- https://master.php.net/note/delete/108734/spam
Del: non-english -- https://master.php.net/note/delete/108734/non-english
Del: in docs -- https://master.php.net/note/delete/108734/in+docs
Del: other reasons-- https://master.php.net/note/delete/108734
Reject -- https://master.php.net/note/reject/108734
Search -- https://master.php.net/manage/user-notes.php