Department of 
Computer Science

Search our Site

Line

ON THIS PAGE:

Course Objectives

Prerequisites

How Does COMP 121 Compare to COMP 110?

Approach

Typical Text

Course Topics

  COMP 121 [015]: Introduction to Functional Programming
(3 hours)

Course Objectives
To teach problem analysis, algorithm design, and the elements of programming, with emphasis upon mastery of concepts, using a functional programming language such as Gofer, Haskell, ML or Scheme. The course will also teach the rudiments of an imperative language as preparation for COMP 401.

Prerequisites
There is no prerequisite, but the course is intended for people thoroughly comfortable with high school mathematics.

How Does COMP 121 Compare to COMP 110?
COMP 110 is intended for students with little or no previous programming experience. Students with a high school course in Pascal or Basic may benefit more from COMP 121 because it emphasizes abstraction and utilizes a different programming paradigm. The course is especially appropriate for students of the sciences, including those intending to pursue further studies in computer science.

COMP 110 and COMP 121 are completely interchangeable in a student's program of study.

Approach
The course emphasizes abstraction in problem solving. The mathematical content is substantial, and there is considerable programming homework.

Typical Text
Thompson, Simon: Haskell: The Craft of Functional Programming. Addison-Wesley.

Bird and Wadler: An Introduction to Functional Programming. Prentice-Hall International.

NOTE: The choice of illustrative applications is at the discretion of the instructor. No course for which COMP 110 is a prerequisite may assume that any specific algorithm or application has been taught in COMP 110.

Course Topics

  • What is Programming? Functional, versus imperative versus others. Introduction to the software. Scripts.

  • The basic tools: Elementary functions and data types.

  • Defining new functions. Local Definitions. Strong typing.

  • Lists. Induction and recursion.

  • Polymorphism.

  • Higher-order functions. (Functions as "first-class citizens".) Currying.

  • Abstract data types.

  • Classes and object-oriented programming.

  • Programming with infinite lists.

The last 2-3 weeks of the course will be an introduction to an imperative language.

Horizontal Line
Department of Computer Science
Campus Box 3175, Sitterson Hall
College of Arts & Sciences
The University of North Carolina at Chapel Hill
Chapel Hill, NC 27599-3175 USA
Phone: (919) 962-1700
Fax: (919) 962-1799
Content Manager: Associate Chairman for Academic Affairs
Server Manager: webmaster@cs.unc.edu
Last Content Review: 7 November 1995