Ruby on Rails Thursday, March 1, 2012

On 1 March 2012 01:05, John Merlino <stoicism1@aol.com> wrote:
> thanks for responses, the ultimate goal was just to ensure a list of
> 500 (no more or less) unique random decimals that are 3 places which
> would be generated only one time. Currently Im storing them as a float
> in the mysql database.

One time for ever? You do realise there's only 1000 numbers between 0 and 0.999?
After two runs, you'll have used up the whole pool.

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.

No comments:

Post a Comment