Better HN
topnewbestaskshowjobs
Log inSign up

sproutini

7 karma · joined Jan 24, 2024 (2y ago) · 9 submissions

Submissions

comment 3w ago · link · parent

Subtyping and generics raise the question of whether containers are covariant or contravariant.

comment 1y ago · link · parent

Overengineered in my view, what is wrong with `x | f` is `f(x)`? Then `x | f | g` can be read as `g(f(x))` and you're done. I don't see any reason to make it more complicated than that.

comment 1y ago · link · parent

> If you don't know why set theory is important, it is because set theory is the foundation of all of mathematics.

Sorry to burst your bubble, but as far as we know, that isn't true in the slightest. It's a logical positivist view abandoned after Goedel and Turing.

At best: What we hope is true is that there often is some axiomatic system where a specific mathematical lemma makes sense when redefined into something similar but not the same.

comment 2y ago · link · parent

The problem with that statement isn't that some APIs use state but that the reason those APIs need state wasn't documented.

comment 2y ago · link · parent

No, not really. A lisp in 99 lines of C would barely be useful. In contrast, Prolog mostly shines where you need reasoning/unification over a database of facts -happens pretty often,- but that's just too easily expressed in any proper functional language. And with a bit more pain in an imperative/OO language.

comment 2y ago · link · parent

The problem with Prolog is that it's based on unification, and small unification engines can be expressed in a few lines in any functional programming language.

That narrows down the already small niche where one would choose Prolog by probably a few orders.

comment 2y ago · link · parent

This isn't news to any logician or people working in formal methods. More like a mathematician getting his head around what has been thought about for decades, if not centuries.

Also, -1 for not mentioning Leibniz equality.

comment 2y ago · link · parent

I still regret I couldn't get a Barry White text-to-speech for the voiceover.