Shell Script Randomizing?
karlp at ourldsfamily.com
karlp at ourldsfamily.com
Sun May 14 04:50:31 UTC 2006
On Sat, May 13, 2006 9:06 pm, inode0 said:
> On 5/13/06, karlp at ourldsfamily.com <karlp at ourldsfamily.com> wrote:
>> How can I create a random number in a bash shell script? I've done a bit of
>> 'google-ing' and `man random, srandom, initstate, setstate - random number
>> generator` and can't find any suitable answers.
>
> Does the RANDOM variable in bash suit your purposes? See "man bash"
> and search for RANDOM. If not, perhaps you could tell us a bit more
> about what you require.
Cool. Now I can limit the values by dividing the result and using the integer
value of the result.
Thanks John.
Karl
>
> John
>
> _______________________________________________
> Redhat-install-list mailing list
> Redhat-install-list at redhat.com
> https://www.redhat.com/mailman/listinfo/redhat-install-list
> To Unsubscribe Go To ABOVE URL or send a message to:
> redhat-install-list-request at redhat.com
> Subject: unsubscribe
>
--
karl
_/ _/ _/ _/_/_/ ____________ __o
_/ _/ _/ _/ _/ ____________ _-\<._
_/_/ _/ _/_/_/ (_)/ (_)
_/ _/ _/ _/ ......................
_/ _/ arl _/_/_/ _/ earson KarlP at ourldsfamily.com
---
Senior Consulting Sys/DB Analyst
http://consulting.ourldsfamily.com
---
My Thoughts on Terrorism In America right after 9/11/2001:
http://www.ourldsfamily.com/wtc.shtml
---
A right is not what someone gives you; it's what no one can take from you.
-Ramsey Clark
---
More information about the Redhat-install-list
mailing list