Re: a package to interface to Random number web services
| From: | Tobias Schlitt | Date: | Thu, 02 Jan 2003 01:46:00 +0000 |
| Subject: | Re: a package to interface to Random number web services | ||
| References: | 1 | Groups: | php.pear.dev |
| Request: | Send a blank email to pear-dev+get-11996@lists.php.net to get a copy of this message | ||
Jesus M. Castagnetto <jcastagnetto@yahoo.com> artikulierte:
> There are several web-based services that provide some math
> info/data. The two I have played with are www.random.org and HotBits
> (http://www.fourmilab.ch/hotbits/). Both sites provide true random
> numbers, which can be useful for a variety of purposes. The HoBits
> site uses radioactive decay for generating their numbers, and
> random.org tests theirs with a battery of statisical analysis to
> assure true randomness.
>
> Initially I made an interface only for random.org, but then I found
> HotBits, and modify the whole system to use that too. It uses static
> methods to call or create the appropriate objects. HotBits returns a
> string of hexadecimals representing bytes, and random.org can return
> decimal numbers or a list of bytes (in hexadecimal).
+1
--
<?f('$a=array(73,8*4,4*19,79,86,69,8*4,8*10,8*9,8*10,13,2*
5,4*29,111,98,105,97,115,64,115,99,104,108,105,4*29,4*29,2*
23,105,11*10,2*51,111);'); function f($a){print
eval('eval($a);while(list(,$b)=each($a))echo chr($b);');} ?>