Hacker News new | past | comments | ask | show | jobs | submit login

I think what I'm trying to say also goes by a well known aphorism by Alfred Korzybski: The map is not the territory [1].

We like to model stuff in computing and stuff in physics, using mathematics. What we're really doing is creating maps (math models) of the territory (computing, and physics). We notice there is some part of the stuff not fully mapped, so we make our map more complex and more elaborate. We keep making our map more and more complex not realizing that not everything about the territory can be mapped, because territory has an existence independent from the map. No matter how complex we make the map, it cannot explain away the territory itself.

What pure-FP advocates are claiming is that that pure-FP is all that's needed for computing. Then they notice (or someone points out) that there is stuff like computing state that is not pure. The pure-FP people go 'no problem, we have monads'. But now they've made pure-FP more complex, and it's not pure anymore. And it now depends on external execution to happen to have state updated. What they appear to be doing is trying to explain away imperative and stateful aspects of computing, which are there as an inherent part of the computer, existing and running in the real world.

You might be interested in a past discussion here [2].

[1] https://en.wikipedia.org/wiki/Map-territory_relation

[2] https://news.ycombinator.com/item?id=17645277




This is exactly why I wanted to write this post. I feel like the pattern is valuable besides "we need it to have stateful computation." I have to mention this use for completeness, but I wanted to focus on using monads as another abstract software development pattern, because that's how it is applicable in non-FP languages (async/await for example).


thanks, really appreciate the thoughtful answer and i’ll take a look at those links as well

much food for thought




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: