Remix.run Logo
▲ raddan a day ago

I can only speak from my own experience, but expressing a program as a composition of pure functions, where effects are carefully managed, is a challenging way of thinking at first. The imperative approach really is simpler to wrap one's head around _until you start worrying about correctness_. I think many developers never really care that deeply, so Haskell never appeals to them. You really do have to take a mathematical approach to program construction. I personally think that the mathematical perspective is liberating, but it's not an easy one to cultivate.

▲tome 6 hours ago | parent | next [-]

> The imperative approach really is simpler to wrap one's head around

I've devised a way of programming imperatively in Haskell but in a way that maintains all the benefits of the type system ("make invalid behaviours unrepresentable") but I don't think that moved the needle on Haskell's popularity...

▲epgui 20 hours ago | parent | prev [-]

I wouldn’t call imperative programming simpler. I’d say it’s more familiar to most people, because it’s the first thing they learn, and it’s hard to unlearn things.