Start reading Real World Haskell: Code You Can Believe In on your Kindle in under a minute. Don't have a Kindle? Get your Kindle here.

Deliver to your Kindle or other device


Try it free

Sample the beginning of this book for free

Deliver to your Kindle or other device

Anybody can read Kindle bookseven without a Kindle devicewith the FREE Kindle app for smartphones, tablets, and computers.
Real World Haskell: Code You Can Believe In
See larger image

Real World Haskell: Code You Can Believe In [Kindle Edition]

Bryan O'Sullivan
5.0 out of 5 stars  See all reviews (1 customer review)

Digital List Price: CDN$ 44.99 What's this?
Print List Price: CDN$ 49.99
Kindle Price: CDN$ 25.50 includes free international wireless delivery via Amazon Whispernet
You Save: CDN$ 24.49 (49%)


Amazon Price New from Used from
Kindle Edition CDN $25.50  
Paperback CDN $49.88  
Save Up to 90% on Textbooks
Hit the books in's Textbook Store and save up to 90% on used textbooks and 35% on new textbooks. Learn more.

Customers Who Bought This Item Also Bought

Product Description

Book Description

Code You Can Believe In

Product Description

This easy-to-use, fast-moving tutorial introduces you to functional programming with Haskell. You'll learn how to use Haskell in a variety of practical ways, from short scripts to large and demanding applications. Real World Haskell takes you through the basics of functional programming at a brisk pace, and then helps you increase your understanding of Haskell in real-world issues like I/O, performance, dealing with data, concurrency, and more as you move through each chapter.

With this book, you will:

  • Understand the differences between procedural and functional programming
  • Learn the features of Haskell, and how to use it to develop useful programs
  • Interact with filesystems, databases, and network services
  • Write solid code with automated tests, code coverage, and error handling
  • Harness the power of multicore systems via concurrent and parallel programming

You'll find plenty of hands-on exercises, along with examples of real Haskell programs that you can modify, compile, and run. Whether or not you've used a functional language before, if you want to understand why Haskell is coming into its own as a practical language in so many major organizations, Real World Haskell is the best place to start.

Product Details

  • Format: Kindle Edition
  • File Size: 1751 KB
  • Print Length: 712 pages
  • Page Numbers Source ISBN: 0596514980
  • Simultaneous Device Usage: Unlimited
  • Publisher: O'Reilly Media; 1 edition (Nov. 14 2008)
  • Sold by: Amazon Digital Services, Inc.
  • Language: English
  • ASIN: B0026OR2FY
  • Text-to-Speech: Enabled
  • X-Ray:
  • Average Customer Review: 5.0 out of 5 stars  See all reviews (1 customer review)
  • Amazon Bestsellers Rank: #87,904 Paid in Kindle Store (See Top 100 Paid in Kindle Store)
  •  Would you like to give feedback on images?

Customer Reviews

4 star
3 star
2 star
1 star
5.0 out of 5 stars
5.0 out of 5 stars
Most helpful customer reviews
5.0 out of 5 stars Five Stars July 24 2014
Format:Paperback|Verified Purchase
I love this computer language and I love this book. Well done!
Was this review helpful to you?
Most Helpful Customer Reviews on (beta) 4.3 out of 5 stars  40 reviews
78 of 83 people found the following review helpful
3.0 out of 5 stars Rich with info, but VERY uneven Oct. 17 2009
By C. Adams - Published on
The good news is, this is probably the best Haskell book yet. The bad news is, it's still a frustratingly confusing jumble. It starts out well, introducing expressions, type inference, recursion, pattern matching, algebraic types, and higher order functions, with an emphasis on maps and folds (the way real world Haskell code is actually written), and it contains exercises that range from simple to challenging. The first four chapters alone are worth the price.

Unfortunately, the problems start in chapter 5, and rarely let up. It starts by introducing a datatype for JSON data for the purpose of pretty-printing it. The way the pretty-printer is rolled out is confusing -- it constantly jumps between code snippets that won't even compile, because a type they depend on is not defined til nearly the end of the chapter. And while it stays away from excessive cleverness, function names are confusingly named. In fact the entire nature of the pretty-printer revolves around a "Doc" abstraction that is never clearly explained or rationalized.

Later chapters are also rich with useful information, such as explanations of various GHC language extensions to the type system (which are really de facto standard Haskell nowadays). Unfortunately (there are many "unfortunatelys" to use in this review) I would never have been able to follow these explanations had I not already known a little about them -- unlike the rest of the examples in the book, the examples stop being "real-world" and instead devolve into meaningless metasyntax like "Foo" and "Bar".

By the time monads are finally introduced (late, but rightly so -- I consider this delay in introducing them to be a plus), the reader has had to suffer through some very tedious projects, such as parsing an obscure binary format. The book really begins to redeem itself again here, and makes monads clear as a datatype that captures common concepts of encapsulating and sequencing, and completely avoids cutesy visual analogies (no spacesuits or toxic waste here!).

I've not finished the book (I'm still in Chapter 14) but I am eagerly looking forward to its later chapters introducing monad transformers, parallel programming, and software transactional memory. You get a lot of book for the price, but you'll need the support of the always-friendly haskell community on IRC or email to make the most of this tome, or even make any sense of several parts of it.
27 of 31 people found the following review helpful
4.0 out of 5 stars Best Haskell book, but not perfect March 7 2009
By Jeremiah LaRocco - Published on
This is probably the best book on Haskell available.

That said, there were some things I didn't like about it.

The biggest annoyance is that the example in Chapter 12 doesn't actually work. The point is to teach Haskell, not how to read barcodes, but example code that doesn't work just seems sloppy.

I'm also not a big fan of how the code samples are spread out over several pages, with a comment stating which file they belong to. Mostly just a pet peeve, but it does cause some problems because there are a few places where the code references variables or types that haven't been declared yet, so the code won't actually compile until you get further along. Not the end of the world, but the book suggests compiling often to avoid errors and the end of each code snippet would be a natural place to do that.

There are also a few language features that are used but not really explained or used before they're explained. The $ operator, for example, is used on page 165 (among other places), but is only briefly explained on page 248. In that case, even when $ is explained it's incidental to explaining something else (fmap and <$>).
37 of 45 people found the following review helpful
1.0 out of 5 stars Poorly organized, and not needed. June 27 2010
By Amazon Customer - Published on
Format:Paperback|Verified Purchase
The book is very poorly organized, and for the life of me I can't think of an ideal audience. Some of the material targets beginners, and then the other seventy percent is completely out of reach to all but seasoned pros. The stuff targeting beginners is rather poorly worded -- the book claims no intro to functional programming is required, but the definitions of fold[lr] will send any beginner scrambling to find a decent explanation. The book has a good share of technical rants that serve to do little more than side-track: "Ok, so you've learned foldr, now for good example and test of knowledge I'll tell you it can be written in terms of foldl" -- no further explanation provided. The definitions are all around bothersome. Ultimately, I don't think I learned much at all from this book, and I'd put in the top two worst O'reilly books I've ever read (following CGI Programming with Perl). This book seems to be a really poor mix of these non-existent books: Beginning Haskell, Advanced Haskell, and the Haskell Cookbook -- and with all this said, Haskell comes off as the most difficult language I've attempted to grasp thus far.

I should add I read through this book twice, and didn't learn much the second time around either.

A ton of the book is devoted to a JSON parser, which is rather tiresome. The other "real world examples" are equally poor like a bit-shifting checksum algorithm.

Go read Learn You a Haskell if you're looking to learn the language. If not, you can try this book -- but I'm going to predict your attempt will be fruitless.
30 of 40 people found the following review helpful
5.0 out of 5 stars The best book on Haskell to come along in a long time Jan. 7 2009
By calvinnme - Published on
Until this book came along you really needed two books to learn Haskell Programming. Haskell: The Craft of Functional Programming (2nd Edition) (International Computer Science Series) teaches the mechanics of Haskell programming, but it can be dry reading. The Haskell School of Expression: Learning Functional Programming through Multimedia shows you the possibilities of Haskell via multimedia programming, but it does miss some basic details about the language that are in the first book. This second book is lots of fun, but I think that the new O'Reilly book replaces the first book entirely and some of the functionality of the second.

Haskell has its roots in academia, and functional programming requires lots of up-front thinking about your total approach. It is not a language where you can usually just sit down and start coding. This book shows you how to use functional programming and Haskell to solve real-world problems. Each chapter contains many code samples, and many contain complete applications. The book contains an application that downloads podcast episodes from the web and stores the history in an SQL database. There is also an application that takes a grainy phone camera photo of the barcode on a book and transforms it into an identifier that you can then ue to query a library website. This is the "fun stuff" that seems to work out so well and so elegantly in the Haskell language.

It is not necessary that you have any prior knowledge of Haskell or functional programming concepts, however general programming concepts are a requirement. This is certainly the first Haskell book to come along in a few years that I would recommend for the novice. As usual with the best of O'Reilly's programming books, this one is well illustrated with lots of well-commented code. The following is the table of contents:

Chapter 1. Getting Started
Chapter 2. Types and Functions
Chapter 3. Defining Types, Streamlining Functions
Chapter 4. Functional Programming
Chapter 5. Writing a Library: Working with JSON Data
Chapter 6. Using Typeclasses
Chapter 7. I/O
Chapter 8. Efficient File Processing, Regular Expressions, and Filename Matching
Chapter 9. I/O Case Study: A Library for Searching the Filesystem
Chapter 10. Code Case Study: Parsing a Binary Data Format
Chapter 11. Testing and Quality Assurance
Chapter 12. Barcode Recognition
Chapter 13. Data Structures
Chapter 14. Monads
Chapter 15. Programming with Monads
Chapter 16. Using Parsec
Chapter 17. Interfacing with C: The FFI
Chapter 18. Monad Transformers
Chapter 19. Error Handling
Chapter 20. Systems Programming in Haskell
Chapter 21. Using Databases
Chapter 22. Extended Example: Web Client Programming
Chapter 23. GUI Programming with gtk2hs
Chapter 24. Concurrent and Multicore Programming
Chapter 25. Profiling and Optimization
Chapter 26. Advanced Library Design: Building a Bloom Filter
Chapter 27. Sockets and Syslog
Chapter 28. Software Transactional Memory
Appendix A. Installing GHC and Haskell Libraries
Section A.1. Installing GHC
Section A.2. Installing Haskell Software
Appendix B. Characters, Strings, and Escaping Rules
Section B.1. Writing Character and String Literals
Section B.2. International Language Support
Section B.3. Escaping Text
7 of 8 people found the following review helpful
2.0 out of 5 stars Not a very good book Feb. 20 2012
By Konstantin Solomatov - Published on
Format:Paperback|Verified Purchase
I have bought the book to improve my understanding of Haskell and its real world usage. Haskell is well known for a very steep learning curve and a lack of good books on it so I hoped the book will improve the situation. Unfortunately, it did so only partially.

The book gives you a deep overview of different language features and libraries. Unfortunately, after reading the book I felt that using Haskell for real world problem is a very bad idea, because of verbose and incomprehensible (and often uncompilable) examples presented in the book which isn't true. This book can only be used as a supplementary material for another haskell book.

For those who are willing to learn haskell I recommend the following sequence of reading: 1. Read Learn You a Haskell for Great Good!: A Beginner's Guide, the book is very short and very easy to comprehend and covers features of Haskell very well. 2. Read Haskell langauge spec. It isn't very long but you will be aware of all the languages' features. 3. Read Monad.Reader for more advanced haskell stuff.
Search Customer Reviews
Only search this product's reviews

Look for similar items by category