4 ms·
It's not functional programming, it's functional languages that go bat shit crazy with the amount of symbols they use that'd make looking at heliographs a refre
by thysultan 5y ago
It's not functional programming, it's functional languages that go bat shit crazy with the amount of symbols they use that'd make looking at heliographs a refreshing pass time.
- Jtsummers 5y agoOut of curiosity, what are the crazy amounts of symbols present in, say, Erlang, SML, Scheme, or Common Lisp?
- throwaway81523 5y agoWe're talking about typed FP so only SML in your list really counts. So let's see: functors, polymorphism, higher-kinded types (does SML have those?), Hindley-Milner type inference, etc. Then for Haskell (the main topic of the linked article), bring in a bunch of unfamiliar algebra such as the notorious monoid on the category of endofunctors. It is actually worth understanding that. I liked this article (prerequisite: some exposure to Haskell): https://www.haskellforall.com/2012/08/the-category-design-pattern.html https://www.haskellforall.com/2012/08/the-category-design-pa... This is also good: https://en.wikibooks.org/wiki/Haskell/Category_theory https://en.wikibooks.org/wiki/Haskell/Category_theory
- Jtsummers 5y ago> We're talking about typed FP so only SML in your list really counts. I like your sense of humor. Appeal to Wikipedia Fallacy: https://en.wikipedia.org/wiki/Functional_programming https://en.wikipedia.org/wiki/Functional_programming LISP certainly shows up in the discussion. It's even called the first functional programming language!
- throwaway81523 5y agoThere's not really an official definition of FP. There are some proposed ones that involve types and some that don't involve them. Mainly though, this is a thread about the linked article, which is about the tribulations that the author had learning Haskell. Most of those tribulations were with the type system and I think that matches most people's experience. You can't transplant it to Lisp.
- bigbillheck 5y agoParentheses count as symbols.
- Jtsummers 5y agoAre there crazy amounts of them? Compared to mainstream programming languages?
- theCodeStig 5y agoIn a LISP, the parenthesis are structural syntax. Where other languages use curly braces, whitespace, square-brackets, and usually a combination thereof; LISP simply uses parenthesis.
- lispm 5y agoIn Lisp parentheses are used as a syntax for nested lists. Lisp programs then are written on top of that with a syntax, which is structural on top of lists. Most other languages don't use a primitive data structure for encoding programs (other than text).
- codr7 5y agoCommon Lisp is about as functional as modern C++, it's a multi paradigm language by design.
- jhgb 5y agoWell, for example standard Common Lisp defines 978 symbols. ;) At least that's what (length (apropos-list "" "CL")) told me.
- the_only_law 5y agoNot only symbols, I’ve stayed away from Scala because half the libraries I’ve looked at seem to want to make their own little DSL the language.
- erik_seaberg 5y agoThat’s the way we ought to be working. If you don’t write the DSL, you’ll have to macro-expand the DSL in your head and write a bunch of boilerplate which everyone will be forced to try to reread and maintain forever.
- lmm 5y agoYou can write a DSL using words rather than symbols, and IME that makes programming a lot easier - you give up very little density and in return you can discuss your code aloud, search for it, ...
- epgui 5y agoI think the word you're looking for is "hieroglyph".