Laboratory exercises (Programming Languages)
From Spivey's Corner
| Programming Languages |
| Syllabus |
| Outline |
| Problems |
| Labs |
| Software |
| FAQ |
Solutions for tutors and demonstrators are on a separate page.
There are three laboratory exercises for the course:
- An exercise asking you to write a functional program for flattening nested lists, transform it into iterative form using an explicit stack, and then rewrite it using assignable variables and a loop. All this will be done in the Fun language that we will be studying in the course.
- An exercise where you will write a monadic interpreter for a language that combines call-by-name with assignable variables. This combination leads to a language with some strange features that are interesting to exploit.
- An exercise in exploring the semantics of a loop-with-exit construct that extends one present in Oberon.
It is suggested that you attempt all three exercises, omitting the first one if it does not seem helpful.
Materials
Instructions for the labs are contained in a laboratory manual. The supporting materials delivered using an anonymous Subversion server in a way described in the lab manual; you can browse the code using the URL http://spivey.oriel.ox.ac.uk/labs/proglan. For safety's sake, I've also provided the materials here, packed into a single archive.
- Source for Lab materials: Gzipped tar format, Windows ZIP format.