Textbooks and Other Resources

Online Textbooks/Readings

There is no textbook to buy for this course. However, I will assign outside reading from the following sources, which are both available online for free. The outside reading complements the lectures and is often able to go into more depth than we have time for in class.

I use the letters M, H, and S on the schedule to indicate reading assignments from these three sources.

M: Math Primer by Andrzej Wąsowski – A very clean and concise refresher on math that is relevant to this course.

H: Introduction to Haskell by Brent Yorgey – An excellent, concise introduction to Haskell. If you’re new to Haskell, don’t skip this reading!

P: Practical Foundations for Programming Languages by Robert Harper – A satisfyingly rigorous treatment of programming languages. Unfortunately uses some non-standard terminology, which I’ll clarify in class. The chapters I’ll assign are all available in the free preview.

Discrete Math

Programming languages is one of the more theoretical disciplines within computer science. As such, this class requires a fluency in discrete mathematics. The most important for this class will probably be (ranked very roughly by importance):

Inference rules – Used to define operational semantics, type systems, and many other kinds of relations on syntactic terms.

Haskell

Throughout the course, we will use the functional programming language Haskell. In particular, we will use Haskell as a metalanguage for describing programming language concepts. It is therefore absolutely essential that you develop your Haskell programming skills!

I recommend that you consult multiple Haskell tutorials/manuals and write Haskell programs outside of class. The following resources should provide several options.

Running Haskell Code

Haskell Platform – The easiest way to start using Haskell. I will assume you have this installed.

Hackage – The central package archive for the Haskell community. There are lots of useful libraries here. Install them using the cabal tool, which comes with the Haskell Platform. First, run the following command to download the list of packages on Hackage.

cabal update

Then you can install new packages by running the following command.

cabal install [package-name]

How to cabal install – A longer tutorial about installing packages from Hackage, in case you run into problems.

Doctest – A useful tool for running examples in comments as unit tests. We’ll use this occasionally in Homework assignments. You can install doctest using cabal install doctest, as described above.

You will probably also need to add the installation directory to your $PATH. Here are my best guesses as to where that will be:

Linux: ~/.cabal/bin

Mac: ~/Library/Haskell/bin

Windows: C:\Program Files\Haskell\bin

Other Haskell Tutorials and Reference Manuals

Haskell: The Confusing Parts – An FAQ especially for folks coming to Haskell from a C/Java background, which I guess is many of the people in this class.

A Gentle Introduction to Haskell – Famous for being not-so-gentle, but a really great and concise resource for refining your understanding of Haskell, once you get the basics down.