[Subject Prev][Subject Next][Thread Prev][Thread Next][Subject Index][Thread Index]

Re: Why am I not getting the results I expect...

>I have a piece of code where I generate a random number between 1 and n.  

You're running Linux, I presume? 

You want to try 

   (random () % 24) + 1

? This should also tell you the index in the array. 



Venkatesha Murthy G.