On 26 Dec 2007, at 19:12, Thufir wrote: > On Wed, 26 Dec 2007 20:50:55 +0900, Frederick Cheung wrote: > >> You known that this produces a floating point number between 0 & 1 >> (i.e >> your case 0 & case 1 statements will just about never be executed? > > 1.) Frederick, you're always helping me out :) > > 2.) I didn't realize that about floating points, I want either one or > zero, of course. > rand(n) with n integer gives you random integers less than n > 3.) I use svn at http://code.google.com/p/dwemthys/source, and I > can go > back a few revisions for an example where it seemed to work (prior to > putting in the db stuff) and the number of iterations matched the > number > of objects instantiated. > > 4.) I'll do a couple prints and so forth on this angle, I seem to > recall > a built in ruby method for converting float to int, too. to_i :-)