Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I love pure programming. But the thing that makes me hesitant to try to learn something like Haskell is that it feels like I need a math degree to understand the concepts and terms. For a while I thought I was just not that smart. But I realise that all these things are just kind of really complicated.


Learning Haskell, if you just want to hack and build a program, is not really complicated and you don't need a math degree or to be particularly smart. You just need to understand it won't be like writing other languages you learned before. That doesn't make it more difficult, just different.


Good to know. I think I get too into my head when reading about it all. Monads? Monoids? Functors? Oh my!

Edit: thank you all for your wonderfully encouraging and useful responses. I know what I'm playing with tonight!!!


It's common.

It's often thought that in order to program Haskell one must understand or use Monads since they are so often mentioned. That's often a mental hurdle for those interested in the language.

Two things to keep in mind here are:

-in the book "An introduction to functional programming systems using Haskell" by A. Davie (1992), Monads (or Functors or Monoids) aren't mentioned at all. That's because they hadn't been architected yet. Monads are not an inherent part of Haskell without which you can't learn or use the language.

-Monads are ordinary data types, even if syntactic sugar is provided. They are not a core aspect of the language.

An explanation I found most useful is http://blog.sigfpe.com/2006/08/you-could-have-invented-monad...

One can just start programming Haskell and ignore Monads if one wants. At some point you will design them or something much like them yourself, making their understanding an "Aha!" moment.


I know the current consensus seems to have moved away from this recommendation [1], but have you tried reading the (free online!) book "Learn You a Haskell for Great Good" (http://learnyouahaskell.com/)? It provides an easy to understand and uncomplicated introduction to monads, monoids, functors, and everything you find scary about Haskell. You won't be able to write full-fledged programs with it, but you won't be scared of these concepts anymore.

[1] The problem with "easy to understand" is that it sometimes leads to oversimplified or wrong intuitions, but to be honest I found the book a nice -- if not immediately useful -- introduction to Haskell.


I've found Professor Frisby's Mostly Adequate Guide to Functional Programming to be the best on ramp. He builds up the concepts carefully till you are using applicative functors and it's always very practical and applied.

I will probably now re-read Learn You a Haskell and actually write some Haskell.

[1] https://drboolean.gitbooks.io/mostly-adequate-guide/content/


I cannot agree more. This book is awesome!


Philip Wadler published this paper[1] titled 'Monads for functional programming' that serves as a good introduction on the subject and is very accessible. It is enumerated through with concrete examples such as 'error handling' using Monads and maintaining 'state' via the State Monad.

[1]: http://homepages.inf.ed.ac.uk/wadler/papers/marktoberdorf/ba...


Just a note, this post has nothing to do with Haskell.




Consider applying for YC's Winter 2026 batch! Applications are open till Nov 10

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

Search: