Personal tools

Haskell in education

From HaskellWiki

(Difference between revisions)
Jump to: navigation, search
m (correct markup)
m (typo)
Line 194: Line 194:
   
   
<b>Instructor:</b> [mailto:hj@sm.luth.se Håkan Jonsson] Luleå Univeristy of Technology, Sweden<br>
+
<b>Instructor:</b> [mailto:hj@sm.luth.se Håkan Jonsson] Luleå University of Technology, Sweden<br>
 
<b>Course:</b> SMD001, functional programming<br>
 
<b>Course:</b> SMD001, functional programming<br>
 
<b>Student background:</b>
 
<b>Student background:</b>

Revision as of 19:12, 26 January 2006

This is a collection of material of interest to those teaching or taking courses that use Haskell. There is also a more general site, http://www.cs.kun.nl/fple/, devoted to all functional languages. The proceedings of the latest International Workshop on Functional and Declarative Programming in Education (FDPE) are now available. Some of the lecture notes and other course material found in these web pages are excellent supplements to the available text books. If you would like to use lecture notes, assignments, or other material found in these course web pages please contact the author for permission.

Most of the entries are years old. When you add your own new material to this page, please also say when the course was run for the last time.

Contents

1 Haskell as a first language

These courses teach Haskell to students with no background in programming.

Instructor: Rex Page University of Oklahoma
Course: Introduction to Computer Programming
Student background: High-school mathematics
Materials: Projects, Exams, Downloadable textbook: Rex Page, "Two Dozen Short Lessons in Haskell"
Web page: http://www.cs.ou.edu/~rlpage/fpclassSpring97/

Comments:

These materials arose from a course offered for three consecutive semesters as an alternative to our usual first course in programming. Most of the students who took the course graduated in the past two years, and many of them cited it in the exit interview with the department chair as the most influential course in the entire academic career.

All materials for two offerings of the course are available through the web page. This includes individual projects, team projects, project solutions, exams, supplied software (connected with certain projects), tips for students taking the course, FAQs addressing questions that students asked during the semester, and a short textbook which served as the primary text in the course.

The first 10 to 11 weeks of the course use Haskell. Students are required to write nine programs in Haskell, three of which are team projects that combine software developed in individual projects. Different members of a team are assigned different individual projects, and the team efforts combine their solutions into a working piece of software.

In the early part of the course, students use operators like map, foldr, zip, and iterate to express computations. Explicit recursion is introduced after some experience with these common patterns of computation. Examples and problems address non-numeric applications, for the most part. Both interactive and file I/O are covered, but general purpose monads are not.

The last 5 to 6 weeks of the course use C, and most of the projects in that part of the course duplicate the function of earlier pieces of software that the students have written in Haskell.


Instructor: Jonathan Hill Oxford University Computing Laboratory
Course: Functional Programming for the Integrated Graduate Development Programme in Software Engineering at Oxford University.
Student background: Discrete mathematics (the course is a part time MSc for people from industry; most are from IBM or Nortel).
Materials: Gofer (an old version, with a stripped down prelude---no parameter classes!); Own course material
Web page: http://www.comlab.ox.ac.uk/igdp/text/course06.html


Instructor: Graham Hutton Department of Computer Science, University of Nottingham
Course: Functional Programming
Student background: None
Materials: Hugs 1.3; Richard Bird, Introduction to Functional Programming using Haskell (second edition), Prentice Hall, 1998. Handwritten slides and exercises; copies available on request.
Web page: http://www.cs.nott.ac.uk/Modules/9899/G51FUN.html


Instructor: " Jan Prins UNC Chapel Hill
Course: Introduction to Functional Programming
Student background: solid background in high-school science and mathematics
Materials: Hugs 1.4 incl. Active Haskell, FRAN and Haskore; Simon Thompson, "Haskell: The Art of Functional Programming"
Web page: http://www.cs.unc.edu/~prins/Classes/15/
Comments:

(Introductory programming course for CS and math/science majors, typically Freshman and Sophomores. Class size ~60) Our undergraduate computing environment is now largely PCs running Windows NT. We use NTEmacs as the programming environment with a slightly modified version of Emacs hugs mode with hugs running as a subprocess. The combined hugs/NTEmacs/Active Haskell distribution (available through course home page) is installed on 400+ public Win NT machines on campus and some unknown number of student-owned Win 95/98 machines. This arrangement is new this semester, but so far has been working well. Keystroke-oriented interactive applications may be problematic with hugs running in NTEmacs shell mode. I'm planning assignments using Fran and Active Haskell and will try teaching the "brief introduction to imperative programming" at the end of the class using monads. I would be interested in talking with anyone who has experience or suggestions along these lines. I took a cue from Paul Hudak and others and have occasional appearances of MS Agents during lectures to wake students up! This is my first time teaching this course, and I would enjoy talking to others teaching at a similar level. A cursory search on the web didn't reveal many courses in this category.


Instructor: David Sands University of Gothenburg & Chalmers University of Technology
Course: Programmering för Naturvetare
Student background: New students
Materials: hugs 1.4; Simon Thompson
Web page: http://www.md.chalmers.se/Cs/Grundutb/Kurser/nptah/
Comments:

This is the first part of a first course in programming. About 16 lectures, each 2x45 mins plus weekly exercise classes and three assessed programming exercises. Most of my materials are in English.


Instructor: Marcos A Rodrigues The University of Hull, Hull, UK
Course: Functional and Logic Programming
Student background: none
Materials: hugs 1.4; Haskell: the Craft of Functional Programming. Thompson S., Addison Wesley, 1996.

Instructor: Torsten Grust University of Konstanz (Germany)
Course: Deklarative Programmierung (Declarative Programming, in german)
Student background: basic math, no programming background required
Materials: Hugs 1.4; (~300) slides available from the course web page; Jeroen Fokker's classroom text: Functional Programming http://www.cs.uu.nl/~jeroen/courses/fp-eng.ps.gz</a>; Richard Bird, Phil Wadler: Introduction to Functional Programming; Simon Peyton-Jones: Implementation of Functional Programming Languages
Web page: http://www.fmi.uni-konstanz.de/dbis/Courses-old/Courses-ss98/decl-ss98.html
Comments:

The course is in German only (sorry about that). It additionally features an introduction to logical programming and Prolog.


Instructor: Richard Buckland University of New South Wales
Course: Computing 1A
Student background: Mixed, some have no computing background. This is our cs1 subject.
Materials: Hugs 1.4; Simon Thompson
Web page: http://www.cse.unsw.edu.au/~cs1011


Instructor: Robert Giegerich, Stefan Posch, University Bielefeld, Germany
Course: Introduction to Computer Science
Student background: Completed High School (Abitur)
Materials: Hugs; Class Notes by Robert Giegerich and Ralf Hinze
Comments:

Our first semester course uses Haskell as a vehicle to fundamental aspects of computation: algorithmics, specification and verification, efficiency analysis, programming methods. This works wonderfully. We do not require previous or additional programming experience. Haskell is quickly learned, to the necessary degreee; we make no attempt to cover the full language. This is NOT a Haskell course! Haskell allows us to speak about concepts of computer science WITHOUT a lot of language learning. And Haskell even helps to keep out detrimental habits from previous programming experience, as well as motivational problems resulting from the widely differing previous experiences of our incoming students.


Instructor: Håkan Jonsson Luleå University of Technology, Sweden
Course: SMD001, functional programming
Student background: None. This is the very first programming course our students take.
Materials: Materials: Simon Thompson's Haskell book + 7 laboratory/programming assignments using Hugs.
Web page:http://www.sm.luth.se/csee/courses/smd/001/ (mostly Swedish)


Instructor: [mailto:Clem.Baker-Finch@cs.anu.edu.au Clem Baker-Finch, Australian National University
Course:CE1
Student background: No programming background was assumed.
Materials: Based on Haskell 1.3; Hugs; Simon Thompson 1st ed.
Web page: http://cs.anu.edu.au/~Clem.Baker-Finch/CE1/
Comments:

The forces of evil (the O-O crowd) prevailed in the programming languages argument and it hasn't been taught since.


Instructor: Lyndon While The University of Western Australia
Course: Foundations of Computer Science
Student background: None
Materials: hugs 98; Thompson.
Web page: http://undergraduate.cs.uwa.edu.au/courses/230.123



2 Haskell as a second language

These courses teach Haskell to students that have already learned another language.

Instructor: Rex Page University of Oklahoma
Course: Discrete Mathematics
Student background: High-school mathematics, introductory programming course (any language)
Materials: Lecture notes, Projects, Exams, Solutions, Proof checking tools, etc.; text: Hall and O'Donnell, "Discrete Mathematics with a Computer"

Web page: http://www.cs.ou.edu/~beseme/
Comments:

Lecture notes comprise over 350 animated slides (all both PowerPoint and PDF formats). About two-thirds of the material centers around mathematical logic. After the introduction of predicates, all of the examples in the logic portion of the course involve reasoning about properties of software, most of which is expressed in Haskell (a few are conventional looping functions).

Software examples include sum, sequence concatenation, logical operations on sequences, the Russian peasant algorithm, insertion and lookup in AVL trees, and other computations. Most of the properties verified relate to aspects of program correctness, but resource utilization properties are also verified in some cases. Several semesters worth of exams (finals and exams given during the term) are provided. The slides have matured through several offerings of the course.

The remaining third of the course discusses other standard topics in discrete mathematics, such as sets, functions, relations, trees, and counting. The web page provides access to a preview of the material. Exams and solutions are protected by a login procedure (to increase the comfort level of instructors wishing to use them in courses). The web page provides a link through which instructors may gain access to the full website.


Instructor: Jose Emilio Labra Gayo, Dept. of Computer Science (EUITIO) University of Oviedo
Course: Logic and Functional Programming
Student background: The course is oriented towards third year undergraduate students in computer science. Usually, the students have been introduced to imperative languages like Pascal and Object Oriented Languages like C++
Materials: Hugs; R. Bird "Introd. to FP using Haskell" (2nd Ed), J. E. Labra Gayo. "Introduction to the Haskell Language" (in spanish).
Web page: http://lsi.uniovi.es/~labra/plf.html (in spanish).

My FP page: http://lsi.uniovi.es/~labra/FuncProg.html


Instructor: Fritz Ruehr Willamette University, Salem, Oregon, USA (a small Liberal Arts College, about 1 hour from Portland & OGI)
Course: CS 451 Topics in Computer Science: Functional Programming
Student background: Data structures (I may also have required discrete math)
Materials: Hugs 1.4 beta (I also taught Scheme); Haskell: The Craft of Functional Programming by Simon Thompson (I also used my own on-line lecture notes and labs and Kent Dybvig's text on Scheme)
Web page: http://www.willamette.edu/~fruehr/451/
Comments:

The notes and labs I have on-line are in pretty rough form: many slide points are just one-line topical stubs I used as reminders in lecture. Many of the on-line materials are not linked into the (out of date) home page. I hope to have the course approved for next Fall as a regular offering (i.e., not as a "special topic") and should have more extensive on-line materials up by then. Teaching "bi-lingually" in Haskell and Scheme seemed like a good idea at the time, but next time around I will use Haskell as the main vehicle, perhaps taking some time near the end of the course to highlight some other languages (Scheme, ML, Clean). Some of my students used Conal Elliot's Fran and Paul Hudak's Haskore and liked them a lot; I was nice to have some significantly-sized applications that seemed more practical and fun to show off at the end of the course (I should have demonstrated these things at the beginning of the course to help with motivation). Next time around I would like to have a "beginner's prelude" or similar available to avoid problems with classes in type inference, Int vs. Integer, etc. These problems were a constant annoyance during lectures.


Instructor: John Hamer, University of Auckland
Course: Logic and Functional Programming
Student background: Year 2 programming + some discrete maths
Materials: Hugs 98, Haskell School of Expression, Page "Two Dozen Short Lessons in Haskell",
Web page: http://www.cs.auckland.ac.nz/compsci360fc


Instructor: Hamilton Richards, University of Teaxs at Austin
Course: CS307 Foundations of Computer Science
Student background: (1) A score of at least 560 on the SAT II Subject Test in Mathematics Level I or Level IC, or a score of at least 530 on the SAT II Subject Test in Mathematics Level IIC, or a grade of at least C in Mathematics 305G (pre-calculus); (2) One year of programming in high school, or a grade of at least C in CS 304P (an introductory course that does not count for credit towards a CS degree), or consent of instructor.
Materials: Hugs 98; Simon Thompson, Haskell: The Craft of Functional Programming.
Web page: http://www.cs.utexas.edu/users/ham/UTCS/CS307/
Comments:

Students who succeed in this course are well prepared for the rest of our CS curriculum, which is more theoretical than most.

Instructor: Chris Lengauer University of Passau
Course: Functional Programming
Student background: two years of CS study
Materials: hugs; Richard Bird's new text (PHI)
Web page: not reachable from outside Passau


Instructor: Conrad Cunningham University of Mississippi
Course: Functional Programming
Student background: official -- senior or graduate standing; actual -- introductory programming, data structures, and discrete math
Materials: Hugs on Unix and MS Windows systems; Mostly use the instructor's own set of lecture notes. Also Simon Thompson's HASKELL: THE CRAFT OF FUNCTIONAL PROGRAMMING. Previously used the Bird and Wadler textbook
Web page: http://www.cs.olemiss.edu/~hcc/csci555/
Comments:

Although I am not a researcher in FP, I enjoy teaching the FP course. Most of the students take to the course after a few weeks. Hugs works reasonably well, but, of course, more pedagogically oriented error messages and other support tools would be helpful.


Instructor: Gary T. Leavens, Iowa State University
Course: Programming Languages 1
Student background: undergraduate course in compilers or programming languaages
Materials: Hugs 1.4; Thompson's Haskell: The Craft of Programming
Web page: http://www.cs.iastate.edu/~leavens/ComS541.html
Comments:

Be sure to tell your students how to debug programs.


Instructor: John O'Donnell University of Glasgow
Course: Functional Programming
Student background: Programming (in Ada), Algorithmic Foundations
Materials: Hugs; Simon Thompson's book on Haskell
Web page: http://www.dcs.gla.ac.uk/courses/teaching/level2/modules/#FP2

Instructor: Olaf Chitil, RWTH Aachen, Germany
Course: Functional Programming in Haskell
Student background: basic programming skills (not necessarily in a functional language)
Materials: Hugs 1.4; Hugs user manual, slide copies; additionally the `Gentle Introduction to Haskell', probably Bird's `Introduction to Functional Programming using Haskell' in the future.
Web page: http://www-i2.informatik.rwth-aachen.de/Praktikum/SWP/ (in German)
Comments:

The course starts with 4 full time days of learning Haskell. During the semester the students (in groups of 2 students) have to implement a compiler and an abstract machine for a simple imperative language. They are given parts of the system and a manual on how to do the remaining parts (they have no prior knowledge on compiler construction). The most difficult construct for students to understand is the monad. I introduce IO without mentioning monads. Later I explain how to build a simple exception handling system based on the type `Maybe a' / `Error a'. Only subsequently I give the general definition of monads and present the list monad and a simple state monad. However, I fear that just to understand the bind operator `>>=' requires people to be quite comfortable with higher-order functions.


Instructor: Richard Bird, Oxford Brookes University
Course: Functional Programming
Student background: Elementary structured programming
Web page: http://web.comlab.ox.ac.uk/oucl/courses/topics00-01/fp/


Instructor: Paul Hudak, Yale University, Dept of Computer Science
Course: Functional Programming
Student background: at least one programming course
Materials: Hugs; my own textbook, which is under preparation
Web page: none


Instructor: Alex Ferguson University College Cork
Course: Functional and Logic Programming
Student background: Final year undergraduate
Materials: Final year undergraduate Materials: Hugs 98; ghc; Simon Thompson, "Haskell: The Craft of Functional Programming" (2nd ed.)
Web page: http://yeats.ucc.ie/~abf/CS4001/
Comments:

This is the declarative programming option for 4th year undergrads, who have Java as a first programming language, and some knowledge of C and C++. The current final year have had some exposure to Haskell in first year, though this is no longer the case for our current intake.


Instructor: Leif Kusoffsky, Royal Institute of Technology, Stockholm
Course: Functional Programming 2D1370
Student background: The course is oriented towards third year undergraduate students in computer science. The students have been introduced to imperative languages like C and Object Oriented Languages like Java
Materials: Hugs; Hudak : The Haskell School of Expression


Instructor: Jeremy Bobbio -- INSIA
Course: Functional and Logic Programming
Student background: One year CS
Materials: Hugs, GHC, Paul Hudak's Haskell School of Education
Web page: http://etudiants.insia.org/~jbobbio/pafp/ (french)



3 Comparative programming languages

These courses teach general programming language principles, with Haskell as an example of a functional language.

Instructor: Ruediger Marcus Flaig, University of Heidelberg (Germany)
Course: An introduction to programming in bioinformatics
Student background: different, but generally low
Materials: Hugs-98 and lots of other stuff
Web page: http://www.sanctacaris.net/rc.html
Comments:

This course is designed to introduce life science students, that is to say, going-to-be biologists, physicians, biotechnologists and maybe others, to solving real-life problems (such as DNA sequence handling and analysis). Emphasis will be on paradigms (imperative / OO, functional, declarative). Although -- in order not to frighten people -- the official announcement mentions only Python, Haskell will be presented as THE purely functional language, and all solutions may be presented in either Python, Haskell or Java. I am very curious about the feedback I'll get, and maybe next term we shall focus more on Haskell. What I'd really need, though, is some life science related package for Haskell, such as BIOPYTHON and BIORUBY.


Instructor: Hamilton Richards, University of Texas (Austin)
Course: Programming Languages
Student background:
Materials: Hugs 1.4; Sethi, Davie.
Web page: http://www.cs.utexas.edu/users/ham/UTCS/CS345/
Comments:

I'm using Haskell in a programming-languages course, but it's distributed somewhat piecemeal through the course. Probably adds up to something like 3-4 weeks (out of 15).


Instructor: Mark Utting University of Waikato (New Zealand) Course: Programming Languages
Student background: Two years of C++ and 1 year of Haskell
Materials: Textbook "Programming Languages", Louden. Web page: http://www.cs.waikato.ac.nz/~marku/313
Comments:

The course covers at least two languages in each of the main paradigms (object-oriented, functional and logic programming), plus history, semantics and implementation issues. The Haskell section is about 2 weeks long and usually focusses on programming with higher-order functions and how that enables the language to be extended in application-specific ways (parser combinators, html-generation combinators etc.)

4 Advanced functional programming using Haskell

These courses deal with the advanced issues such as semantics, type systems, or compilers. Includes a other advanced courses taught using Haskell.

Instructor: John Hughes Chalmers University, Gothenburg
Course: Advanced Functional Programming
Student background: General CS maturity; from this year most students have already used Haskell in introductory courses.
Materials: Mainly hbc.; Papers (see web page)
Web page: http://www.cs.chalmers.se/~rjmh/AFP
Comments:

The goal is to teach students how to solve substantial problems in a functional language --- `functional programming in anger', one might say. The emphasis is on design and use of suitable combinator libraries to simplify applications. Material covered includes monad design, use of CPS style, libraries for parsing, pretty-printing, and GUIs (presently fudgets). The course is taught in a `problem based' manner: lectures are few, while students solve three substantial programming problems during the term, with plenty of backup via group meetings. I adopted this teaching form three years ago, and it has led students to develop far better practical skills than most obtained from my earlier `lectures and exercises' courses, and I believe to use Haskell much more after the course's end. This course is optional in the third or fourth year, and is taken by a small-to-medium sized group of students.


Instructor: Olof Johansson, Umeå Univesity, Department of Computing Science
Course: Programming language semantics
Student background: two terms of computer science studies and specificaly a course Programming language concepts
Materials: Hugs and some HBC and GHC; Watt, Programming language, Syntax and Semantics
Web page: http://www.cs.umu.se/local/kurser/TDBC05(Only in swedish)


Instructor: Lyndon While The University of Western Australia
Course: Functional Programming
Student background: OOP, plus most of them have used Haskell previously
Materials: hugs 98; none of the recent books really fit
Web page: http://undergraduate.cs.uwa.edu.au/courses/230.301
Instructor: Fethi Rabhi, University of Hull (UK)
Course: AI Problem Solving Techniques (using Haskell and Prolog)
Student background: Haskell and Prolog programming
Materials: HUGS; Thompson'96, own notes (soon to be published as a book).
Web page: none
Comments:

It is very hard to justify learning Haskell unless it can be demonstrated in very practical situations (hence the provision of the above course).


Instructor: Jerzy Karczmarczuk University of Caen, Caen (France)
Course: Compilation
Student background: General CS knowledge; students (should...) know Scheme and imperative languages, also some theory of languages and automata.
Materials: Hugs, GHC, now also GHCi, and their documentation. Handouts: (still a little incomplete)

Comments:

This is a compulsory semestrial course in fourth year. Weekly: 1.5h course, 2.5H practice. One, but comprehensive assignment, taking 2 months or more. askell is our main coding tool. A little time is devoted by necessity to the language itself, but also from the perspective: "how would you compile such a language". "Standard stuff", such as parsing combinators, etc.is covered, but we don't begin with that. We start with the construction of small interpreters: from recursive Lisp-style to postfix, (Forth/PostScript style) constructing this last by partial evaluation (intuitively). We introduce control structures as lazy functions, operation sequencing through continuations, monads not only for parsing, but also for exceptions and non-determinism. We discuss (simply) the type inference. The code generator assembles a linear code by lazy concatenation of chunks which makes it trivial to deal with loops and cross-referencing fragments. Algorithms of garbage collection are presented (not implemented, though...) in a purely functional style. Students' opinion: "Frightening at first. Learning curve steep, but much less time spent on debugging, coding proficiency comes fast. Good for understanding what the compilation is about, but difficult to make a complete running program with all the I/O, etc.


Instructor: Jeffrey A. Meunier, University of Connecticut
Course: CSE240 Intermediate Computer Systems
Student background: computer/microprocessor organization
Materials: Hugs (Feb 2001); Bird ``Introduction to Functional Programming; Furber ``ARM System-on-Chip Architecture
Web page: http://www.engr.uconn.edu/~jeffm/Classes/CSE240-Spring-2001/index.html
Comments:

This is a course in the low level programming of microprocessor systems. The course will focus on the development of an emulator (virtual machine, or VM) for a small computer system based on a modern RISC microprocessor (the ARM CPU) using a high level programming language (Haskell), and assembly language programming of the VM. Development of the VM will occur in stages, starting with the simple direct-execution (stream-based) model, gradually moving to a more realistic memory-mapped model, including exception handlers, concurrent processes, and asynchronous external devices.