cvs: phpdoc /en/functions math.xml
| From: | Zak Greant | Date: | Mon, 15 Oct 2001 22:51:36 +0000 |
| Subject: | cvs: phpdoc /en/functions math.xml | ||
| Groups: | php.doc | ||
| Request: | Send a blank email to phpdoc+get-969338006@lists.php.net to get a copy of this message | ||
zak Mon Oct 15 18:51:36 2001 EDT
Modified files:
/phpdoc/en/functions math.xml
Log:
Minor fix to the *srand make_seed() function
Index: phpdoc/en/functions/math.xml
diff -u phpdoc/en/functions/math.xml:1.54 phpdoc/en/functions/math.xml:1.55
--- phpdoc/en/functions/math.xml:1.54 Fri Sep 21 18:47:42 2001
+++ phpdoc/en/functions/math.xml Mon Oct 15 18:51:36 2001
@@ -1,5 +1,5 @@
<?xml encoding="iso-8859-1"?>
-<!-- $Revision: 1.54 $ -->
+<!-- $Revision: 1.55 $ -->
<reference id="ref.math">
<title>Mathematical Functions</title>
<titleabbrev>Math</titleabbrev>
@@ -796,8 +796,8 @@
<programlisting role="php">
// seed with microseconds
function make_seed() {
- list($usec,$sec) = explode(" ", microtime());
- return ((float)$sec+(float)$usec) * 100000;
+ list($usec, $sec) = explode(' ', microtime());
+ return (float) $sec + ((float) $usec * 100000);
}
mt_srand(make_seed());
$randval = mt_rand();
@@ -1229,8 +1229,8 @@
<programlisting role="php">
// seed with microseconds
function make_seed() {
- list($usec,$sec) = explode(" ", microtime());
- return ((float)$sec+(float)$usec) * 100000;
+ list($usec, $sec) = explode(' ', microtime());
+ return (float) $sec + ((float) $usec * 100000);
}
srand(make_seed());
$randval = rand();