
Why Perl 6 isn’t COBOL nor Python nor Java (or… having fun with Rats) - lizmat
https://medium.com/@jcoterhals/perl-6-small-stuff-4-why-perl-isnt-cobol-nor-python-nor-java-or-having-fun-with-rats-306d0addb46f
======
nwatson
>> Statistics and ML/AI math is all the rage these days. What they depend on
is correct math.

Statistical applications might benefit from more precise rational numerics,
but machine learning and AI are piles of imprecise heuristics ... There is no
benefit to using slower and more precise numerics there.

~~~
raiph
You've written precisely what I thought about that...

------
al2o3cr
Rationals are an interesting default choice, since they can have nasty
performance corner-cases related to finding GCDs for large integers. For
instance, note that the numerator & denominator of the rational results are
both growing at (roughly) an order of magnitude per iteration.

~~~
raiph
The default rational type isn't unlimited precision.

See my comment at
[https://www.reddit.com/r/perl/comments/93dabg/perl_6_small_s...](https://www.reddit.com/r/perl/comments/93dabg/perl_6_small_stuff_4_why_perl_isnt_cobol_nor/e3e21s4)
for an explanation and demonstration of P6's approach.

