On Tue, Jun 16, 2015 at 10:02 PM, Michael Zedeler <mich...@zedeler.dk>
wrote:

> I'm not saying that there isn't any alternative to the way other languages
> implements floats, but Rats in particular seems to require a
> nondeterministic algorithm in order to be of practical use.
>
  Rats means never having to worry about inaccurate float representations.

$ perl -E '$i+=0.1 for 0..1000; say for $i, $i cmp 100.1' # oops …
100.099999999999
-1
$ perl6 -e 'my $i; $i+=0.1 for 0..1000; .say for $i, $i cmp 100.1'
100.1
Same
$

  Float inaccuracy is one of the things I'm really looking forward to
forgetting. :)


Eirik

Reply via email to