Data-Random reviews

cpanratings
 

RSS | Module Info | Add a review of Data-Random

Data-Random (0.05) *****

I needed to take n random elements from a set, and I didn't feel like writing much code. I ran 'apropos Random' on my machine, and it spat out Data::Random, something that must have been installed as a prerequisite for something else.

I checked out the manpage, and cut and pasted a single line of code and I was done. The API is very nice and offers ways to generate random words, dates, times, characters, sets and selections.

For instance, just for fun, if you want to select next week's winning Lotto numbers, something like:

print for rand_set(set => [1..50], size => 6);

will print them out for you (adjust the values to respect your local specifications). If you win, I'll settle for a 2% cut.

David Landgren - 2009-12-16T07:48:29 (permalink)

2 out of 2 found this review helpful. Was this review helpful to you?  Yes No

Data-Random (0.05) *****

I haven't looked under the hood, but it (Data::Random::WordList) did what I needed, so I didn't have to write the code.

Robert Rothenberg - 2009-04-29T12:55:16 (permalink)

1 out of 1 found this review helpful. Was this review helpful to you?  Yes No