[prev in list] [next in list] [prev in thread] [next in thread]
List: ruby-talk
Subject: Re: Exact (LISP-ish) calculations in Ruby?
From: Aldric Giacomoni <aldric () trevoke ! net>
Date: 2009-11-18 18:14:22
Message-ID: 644ca0f34e33332c171dbb0bb960523b () ruby-forum ! com
[Download RAW message or body]
David Masover wrote:
>
> irb(main):002:0> Rational(3) / 4
> => (3/4)
> irb(main):003:0> Rational(3) / 4 / 12
> => (1/16)
>
> I'm not sure about the rest of it, though it makes me wish I'd used Lisp
> for a recent project.
In all fairness, I just fired up SLIME to check, and LISP's (sqrt 2)
does come out to be an approximation, so I guess I want something cool
like the HP-48 and HP-49's factoring power..
--
Posted via http://www.ruby-forum.com/.
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic