Mark Seemann feels that mutating state is intuitive

(written by lawrence krubner, however indented passages are often quotes). You can contact lawrence at:

This is a case of someone trying to be open-minded, but still being biased because of their years spent getting comfortable with a very particular form of programming that allows a very particular form of mutable state:

In FP they’ve come up with this clever concept of monads to ‘work around’ the problem of mutating state. Yes, monads are very clever, but if they feel foreign in OOD it’s because they’re not required. Mutation is an inherent part of the OOD paradigm, and it very intuitively maps to the ‘real world’, where mutation happens all the time. Monads are cool, but not particularly intuitive.

But does he mean sequential mutation, or concurrent mutation? Is there anything intuitive about concurrent mutation in Object Oriented Programming? It’s a nightmare.

Seemann should consider the counter-argument that Joe Armstrong (inventor of Erlang) gives in his thesis:

In the real world sequential activities are a rarity. As we walk down the street we would be very surprised to find only one thing happening, we expect to encounter many simultaneous events.

If we did not have the ability to analyze and predict the outcome of many simultaneous events we would live in great danger, and tasks like driving a car would be impossible. The fact that we can do things which require processing massive amounts of parallel information suggests that we are equipped with perceptual mechanisms which allow us to intuitively understand concurrency without consciously thinking about it.

When it comes to computer programming things suddenly become inverted. Programming a sequential chain of activities is viewed as the norm , and in some sense is thought of as being easy, whereas programming collections of concurrent activities is avoided as much as possible, and is generally perceived as being difficult.

I believe that this is due to the poor support which is provided for concurrency in virtually all conventional programming languages. The vast majority of programming languages are essentially sequential; any concurrency in the language is provided by the underlying operating system, and not by the programming language.