Clear questions and runnable code get the best and fastest answer |
|
PerlMonks |
Re: random num generatorby Roger (Parson) |
on Jan 20, 2004 at 12:57 UTC ( [id://322573]=note: print w/replies, xml ) | Need Help?? |
You could start with Perl's built-in rand function. Type the following at command-line to get the documentation on rand:
What sort of data structure are you thinking about? I would probably store the elements in a hash table with gate ID as lookup key:
If I want to insert 20 random input values between (-1.0, 1.0) to gate001:
In Section
Seekers of Perl Wisdom
|
|