BOTW: Real World Haskell

This week I re-read “Real World Haskell”. It is textbook that teaches the Haskell programming language. The book is legally freely available from that link, so I encourage you to check it out, regardless of what I’m going to say about it.

The Value of ‘Real World’

Haskell first appeared in 1990. But it has only been in the past five or six years that I have seen the language swell in popularity, leading many people to be surprised at how old Haskell is—the same goes for Python, Ruby, which are also older than most realize. Haskell seemingly has become the most prominent strongly-typed, purely functional language. However, I believe the Haskell community does a poor job of making the language accessible; you will find no end to articles about monads, Hindley-Milner type inference, category theory, and so on. Many of these articles are filled with the kind of mathematics that makes a lot of people run for the hills.

Now let me be clear: I am not criticizing those authors for writing such material. I do not want it to sound like I am devaluing the merit of the type of programming literature you find on sites like Lambda the Ultimate. That type of academic writing is important the programming field; for example, mathematical proofs related to type inference lead to performance boosts in compilers. But when it comes to learning Haskell most programmers, in my experience, are more confused than anything else by such literature.

This leads into the reason Real World Haskell is such a great book: it takes a language often dressed up in formulae and breaks it down in a way that only makes the language easily approachable. Even more importantly, the words ‘real world’ in the title are key: the book teaches you Haskell while also showing you that it is perfectly viable for such projects as web software, interacting with relational databases, desktop GUI applications, et cetera. Haskell is a great language for exploring subjects like lambda calculus but Real World Haskell shows you that it’s equally useful for scanning and processing barcodes.

The authors do a wonderful job of explaining Haskell’s concepts in a way that is understandable to novice programmers. It travels through the high-level concepts of monads and type-classes and purely-functional programming with clear, informative explanations. And then it supplements those by showing you how all of that benefits and facilitates writing real world, production-quality software. I would not blame anyone for thinking that Haskell is only useful for code in doctoral theses, such is the pervasive atmosphere of the Haskell community. But Real World Haskell demonstrates that the language is a powerful tool outside of the ivory towers of academia. Think that it would be a pain in the ass to use Haskell for web development? Wrong—it has great frameworks like Yesod.

Real World Haskell is terrific and deserves a glance by anyone who is thinking about writing off Haskell as an unpractical programming language. Even if you are thoroughly educated on the mathematical foundation of the language I would still recommend this book for learning Haskell. I have yet to see any other Haskell text which comes close to being as readable, accessible, useful, and practical as Real World Haskell.

Next Book of the Week

My next book to read is “Fundamentals of Computer Graphics”. As I wrote about a few weeks ago, I will give myself two weeks to read this book instead of the usual one, as it is over five-hundred pages in length. Trying to read such long books in seven days has become unfeasible these days. Besides, as a game developer I want the extra time to soak up all the information I can about computer graphics because that is a field I have to deal with head-on. So I’m looking forward to sitting down with the book and re-enforcing my understanding of the fundamentals behind computer graphics.

One thought on “BOTW: Real World Haskell

  1. I failed to mention one other book:

    It is also freely available. Personally I believe “Real World Haskell” is better, but it would be a huge mistake on my part to not mention “Learn You a Haskell For Great Good!” as it is another wonderful book for people who are complete Haskell novices.

Add Your Thoughts

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s