Effective Functional Programming

COMP 4600/5300 - 205


  • Term: Fall 2022
  • Time: Monday 3:30pm – 6:20pm
  • Place: Falmouth Hall, Room 311 (North Campus)
  • Intructor: Paul Downen <paul_downen@uml.edu>
  • Office: Dandeneau Hall, Room 305
  • Office Hours: Wed+Thur 3:30pm – 5:00pm, or by appointment

Class Description

As software enters more and more of our daily lives, it also becomes larger and more complex. Programmers must control the many ways their software interacts with the real world: user input and output, large structured and unstructured data sets, shared resources, communication between networks of devices, and control over real-life machines. Each of these implicit interactions in software creates unintended complexity, making it harder to understand the overall system. Issues surrounding the safety, security, and correctness of software are all symptoms of this problem.

Functional programming techniques give software developers fine-grained control over these interactions, providing a source of modularity and composability that helps tame ever-increasing complexity. This benefit has found applications in both high-assurance systems, where the cost of bugs is high, and in concurrent and distributed systems, where leveraging multiple cores or machines requires carefully planned communication and coordination.

This course is about how functional techniques can be used to write a wide variety of practical programs, including games, data structures, and concurrent programs. The course covers advanced features found in modern functional languages and their use in software development, with a particular focus on using types to describe the external side-effects of programs, and to automatically eliminate sources of bugs early in the software development process.

The class will be primarily project-based, where students will be tasked with developing several programs they can interact with, ending with a final capstone project. Haskell, which is a platform for both practical software development and cutting-edge technology, will be used as the main language for studying functional programming techniques. Note that students are not expected to have previous experience with Haskell, and an introduction will be given at the beginning of the course.

Class Objectives

At the end of this course, students should be

  • • confident in their ability to use a functional language to approach any programming problem of their choosing,
  • • familiar with a variety of functional techniques and their application to algorithmic problem solving,
  • • able to apply (semi)formal methods for understanding, debugging, improving, and extending their software, and
  • • aware of how to transfer their knowledge from this class to other paradigms, like object-oriented programming.


Prerequisite: Department approval

Suggested prerequisite: Organization of Programming Languages, Design of Programming Languages, Compiler Construction, or equivalent.

Students should be comfortable with basic general programming concepts (recursion, data types and structures, etc.) and be able to design and write significant programs in some language. Previous experience with Haskell or another functional language (Scheme, OCaml, F#, Scala, Clojure, ...) is a plus, but not necessary.