June 16, 2020

Learning Haskell

Hands down, the best resource for learning Haskell is the book, "Learn You a Haskell for Great Good!". Do not be put off by the title, the humor, or the illustrations. On the contrary, pay careful attention to everything he has to say and take your time working through the book.

The temptation is to take the light hearted humor as an indication that the book is not serious. This is a big mistake. Another big mistake is trying to skip things that don't seem important. All the details are important, and the order they are presented by the author is carefully chosen.

Another tip. Don't think that you have a clue based on experience with other languages. Take Haskell types as an example -- these are very different from anything you have seen before. If you don't pay attention to "type classes", you are going to have serious trouble later on. As another example, take the "return" statment. It does something totally unexpected and very definitely not what you expect from other languages.

Stick with this book and you will be well rewarded. I spent a lot of time with it online and then purchased a printed copy.

Other resources

I bought the book "Real World Haskell" and was quite disappointed. It starts out well, then chapter 10 drops you off a cliff. The book is getting old, but that is the least of its problems. It is available online, so you can get annoyed without spending money.

I also bought "Haskell: the Craft of functional programming" and thought it was a waste. It is a textbook, covers only the basics, and was a let down for me. My money would have better been spent elsewhere.

The book "Parallel and Concurrent programming in Haskell" is recommended by some. It dates from 2013. The author has been a major player in Haskell itself and the book is recommended for examples of real programming.

The following are recommended online resources:

Stephen Diehl's essay on "what I wish I knew ..." seems to have turned into an exhaustive reference on all of Haskell rather than a few wise pointers. I think I new title is in order.

Write programs !

In every language I have every learned to use effectively, the majority of my learning comes from writing code, not reading books. Books certainly prime the pump, but to learn Haskell you ought to spend more time on the computer than with your nose in a book.
Feedback? Questions? Drop me a line!

Tom's Computer Info / [email protected]