Programming thread

it has lots of those batshit insane "elegant" syntax sugar that looks like some retarded haskell shit and then you try to do a closure and you have to declare your variable "nonlocal" which makes very little sense
These are annoyances but on balance I find Perl 5 more annoying and also there are various alternatives to list comprehensions. Medium and sites using its CMS tend to generate a lot of clickbait titles and this seemed like one of them but it was actually pretty decent:
pacman -Ql perl | grep Math
maybe the arch packagers included some stuff from cpan in the standard perl for some unknown reason but it doesn't seem very 3rd party if it comes bundled in with the interpreter
I looked and Mint has a similar thing going on ... you are in fact right (search "BigInt" in files here: https://github.com/Perl/perl5) so it's strange that the code would also be on CPAN. I take back at least part of what I had to say about Perl and arbitrary-precision integers but it appears that true decimal arithmetic for example really is third-party code.
 
Can a code get demonically posessed?
Can satan be in a code itself, a code that looks innocent?
or does it have to be written in a specific way?
what the fuck are you talking about? the code is simply what controls the spirit that lives inside the computer to do the magician's bidding
the processes generated by such code can be varying levels of fucked up though
I looked and Mint has a similar thing going on ... you are in fact right (search "BigInt" in files here: https://github.com/Perl/perl5) so it's strange that the code would also be on CPAN.
maybe cpan just indexes modules that are developed in the perl tree because i don't see a huge reason why doing that would be bad
I take back at least part of what I had to say about Perl and arbitrary-precision integers but it appears that true decimal arithmetic for example really is third-party code.
i also see big rational numbers in the package and i think it can do infinite precision decimal arithmetic if you use it right
 
  • Thunk-Provoking
Reactions: Belisarius Cawl
To quote the Spartans: "if". I really just want to be able to do stuff like Decimal('0.1') + Decimal('0.2') and not worry.
Perl:
use Math::BigRat;
print Math::BigRat->new("1/10")->badd(Math::BigRat->new("2/10"));
# => 3/10 (exact number)
it claims to manipulate fractions with infinite precision which i believe is good enough
are there any weird footguns with working in rational and converting to decimal at the very end?
 
Back