The Haskell Cheatsheet

codeslower.com Savor Your Code.

The Haskell Cheatsheet

Justin Bailey <jgbailey@codeslower.com>

Learning Haskell is not easy. Besides the syntax, concepts, and advanced types, there is a real lack of succinct, accessible references. As I learned Haskell I frequently wanted a quick reference for syntax, keywords and other language elements. The Haskell Report, while very thorough, wasn't quite it.

For that reason I've created this cheatsheet. It's intended for beginning to intermediate Haskell programmers to use as a quick-reference guide for syntax, keywords or other language issues. You can obtain it in four different ways:

  • Download directly in PDF format: CheatSheet.pdf
  • As a Haskell package on HackageDB.
    • After downloading, unpack the tarball and the PDF is inside.
  • Using cabal install with "cabal install cheatsheet". Afterwards, run the "cheatsheet" program and it will tell you where the PDF is located.
  • The Haskell Cheatsheet from Amazon.com, formatted especially for the Kindle eReader.

The guide itself is written as a "literate" Haskell file, meaning it is directly executable. That file is available when using the latter two options above.

The source is hosted at http://github.com/m4dc4p/cheatsheet/tree/master and can be cloned from git://github.com/m4dc4p/cheatsheet.git.

¿Usted habla español?

Jaime Soffer was kind enough to translate the Haskell Cheatsheet into Spanish! Just download CheatSheetEs.pdf from his GitHub repository.

Anata ha Nihongo wo hanashimasuka?

Yuji Ichikawa has translated the Haskell Cheatsheet into Japanese. Download it now: CheatSheet-ja.pdf.