The Haskell Phrasebook
The Haskell Phrasebook is a free quick-start Haskell guide comprised of a sequence of small annotated programs. It provides a cursory overview of selected Haskell features, jumping-off points for further reading, and recommendations to help get you writing programs as soon as possible.
To follow along and run the code examples, get the source files from github.com/typeclasses/haskell-phrasebook.
The code may be modified and redistributed for any non-commercial purpose with attribution.
Here is the complete list of libraries utilized by the example programs:
baseis the standard library, required by every Haskell program.
Seqwhenever we will need to retrieve a value from a particular position in a list.
timefor holding time in the palm of our hands.
We represent byte arrays using the
ByteStringtype from the
We use some utilities from the
memorylibrary for working with byte arrays.
We use the
safe-exceptionslibrary for handling I/O exceptions.
When we write a program that runs indefinitely, we use the
signallibrary to listen for a termination signal.