note 58866 added to function.gmp-mod
| From: | wm_maw at evonet dot ro | Date: | Fri, 18 Nov 2005 07:51:23 +0000 |
| Subject: | note 58866 added to function.gmp-mod | ||
| Groups: | php.notes | ||
| Request: | Send a blank email to php-notes+get-98747@lists.php.net to get a copy of this message | ||
If you have the windows version you can do it like this:
<?php
// first value
$i=9;
// second value
$b=5;
echo "How to manage ".$i." mod ".$b."<br/>";
//here we make the big calculations :)
$manager = (int)($i/$b);
$modulo = $i-$manager*$b;
// and we print it
echo $modulo;
?>
it's simple but it will save you time ;).
----
Manual Page -- http://www.php.net/manual/en/function.gmp-mod.php
Edit -- http://master.php.net/manage/user-notes.php?action=edit+58866
Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+58866&report=yes&reason=added+to+the+manual
Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+58866&report=yes&reason=bad+code
Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+58866&report=yes&reason=spam
Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+58866&report=yes&reason=useless
Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+58866&report=yes&reason=non-english
Delete: already in docs -- http://master.php.net/manage/user-notes.php?action=delete+58866&report=yes&reason=already+in+docs
Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+58866&report=yes
Reject -- http://master.php.net/manage/user-notes.php?action=reject+58866&report=yes
Search -- http://master.php.net/manage/user-notes.php