--nextPart1250230.5gGxXYnGQu
Content-Type: text/plain;
  charsettf-8"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline

Quoth Peter Roome:
> > Just off-hand, my initial reaction would be:
> > 
> >   (a * 20).round.to_f/20
> > 
> > where "a" is your variable.  Some quick tests with irb seems to show
> > this as working.
> > 
> > Coey
> 
> Cheers for the quick response guys, much appreciated. What difference
> would the .to_f make between these solutions?
> -- 
> Posted via http://www.ruby-forum.com/.

One solution used (expr).to_f/20, the other used (expr)/20.0.
Both of these ensure floating point division is used instead of integer 
division, that's all.

-- 
Konrad Meyer <konrad / tylerc.org> http://konrad.sobertillnoon.com/

--nextPart1250230.5gGxXYnGQu
Content-Type: application/pgp-signature; name=signature.asc 
Content-Description: This is a digitally signed message part.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)

iD8DBQBHIkjLCHB0oCiR2cwRAnUUAJ4gq8/7rPgpiPsVOHaePg+ZQtVv4ACbBLvB
Oqz8l9veI8ZV85bS60VfsPA/k
-----END PGP SIGNATURE-----

--nextPart1250230.5gGxXYnGQu--