4 ms·
You could consider it trolling of me to submit this here. However, rather than rehash the discussion of the advantages of functional programming, I would like t
by Confusion 14y ago
You could consider it trolling of me to submit this here. However, rather than rehash the discussion of the advantages of functional programming, I would like to focus on a specific issue this article exemplifies: why isn't functional programming catching on?
Why are these 'scary' code examples used as an indication of what 'functional programming' looks like, instead of entirely reasonable Ruby, javascript or even Java snippets? How is it that proponents continue to fail to make it clear that functional programming can be done, to some extent, in any language and that it still has advantages?
- lextori 14y agoIt is easier to pull out scary and obscure bits of code from languages that have arcane syntax. I'm sure that it'd be pretty easy to find some c++ code that is even more difficult to read. The whole article seemed to me to be a big "waahh this is hard, and looks funny" rather than a serious discussion of the advantages and disadvantages of functional programming.
- Lambdanaut 14y agoI agree. Also, the code examples were very poor in making any point. Coming from somebody with a functional background but with no Erlang experience, the Erlang was trivially clear to me in its purpose. The Haskell would be much clearer if it wasn't missing a type signature.
- sp332 14y agoI've been leaning heavily on functional programming in my Python code lately. I understand that Guido doesn't want Python to become a full-blown functional language. But I find that, at the very least, avoiding explicit loops makes my code easier to understand.
- shoo 14y agoThe author of the article does not appear to be a proponent of functional programming, or at least does not appear to be a proponent of the syntax used by a number of functional languages. These code examples are used by the author of the article to support the point he is trying to make. I imagine these are probably pretty good examples to use for the target demographic of javaworld.