Dave
Naumann
with office hours: Mon 10-11, Mon 3-5, and by appointment.
Hardikkumar Rameshchandr Akhani, office hours: Wed 2-3
CS 590 and MA 502.
Monday 6:15-8:45PM, Pierce 120
- Essentials of Programming Languages
(EOPL) - 2nd ed., by Daniel P. Friedman, Mitchell Wand, and Christopher T. Haynes.
Publisher: MIT Press ISBN: 0-262-06217-8
- The Little Schemer - 4th Edition,
by Daniel P. Friedman and Matthias Felleisen.
Publisher: MIT Press ISBN 0-262-56099-2
We will use the DrScheme system which is available on the
CS Lab machines and can be downloaded here
for
other platforms.
Much of the code used in EOPL can be downloaded from the
EOPL home page.
cs510
The currently popular computer language is constantly changing. Fifteen years
ago it might have been Pascal or C; 10 years ago it was probably C++; today it
is probably Java (or C#). Now it seems time for another change. There are a
host of other languages (Perl, PHP, Visual Basic, JavaScript, Python, Ruby,
Haskell, Mercury, etc...) that are popular for their own classes of problems and
programming styles. Therefore, to have a career in software engineering
means having to learn new programming languages.
To meet your need to learn new programming languages quickly, and to help you
work better with the languages you do use, this course seeks to provide a forum
where you can develop an understanding of the basic design decisions that are
part of every programming language. Things like:
- How does one divide programs into manageable pieces?
- What conceptual models can be used for translating a real world problems into programs?
- What are good ways to express programming idioms?
- What features must a programming language provide?
- What additional features will help simplify things for users?
- How does one precisely describe a programming language?
- How should a language be implemented?
Our technique for studying these questions will be two-fold. First we will learn
the functional programming language Scheme. Functional programming is much
different from the imperative programming that most of us are used to from
languages like C++, Visual Basic, or Java. Learning functional programming helps
one to develop a more thorough understanding of the various ways of organizing
programs.
After we have developed some experience with Scheme we will develop a series of
interpreters for various small programming languages. These interpreters allow
us to experiment with various design decisions, how those decisions interact,
and how different language features are implemented.
These essential objectives will be helpful for your career as a
software engineer or computer scientist; hence we want to help you to master them.
In one sentence, the main objective is that you will have a deep, working
knowledge of the functional paradigm and the key ideas used
in modern programming languages. In more detail the essential objectives for
this course are that you will be able to:
- Write and modify programs using a mostly-functional style.
This means programming that makes effective use of the abstraction
mechanisms of functional languages, such as higher-order functions (functions
that take functions as arguments and return functions as results) to achieve
generality and abstraction.
- Write and modify programs that make effective use of data abstraction.
- Modify interpreters to change or enhance their behavior so as to implement
various features of programming languages including:
control flow, variables, recursion, scoping, syntactic sugars, arrays,
parameter passing mechanisms, type checking, objects, classes, and
inheritance.
- Write programs using such features, and explain, using appropriate
terminology, the user-visible behavior and performance of such programs.
- Explain, using appropriate terminology, the data structures and algorithms
used in interpreters to implement such features.
- Compare alternatives in the design and implementation of such features.
In particular you will be able to
- Explain the difference between implementation and inheritance, and between
subtyping and inheritance, using object-oriented languages such as Java and C++
as examples.
- Explain the difference between subtype and parametric polymorphism.
- Explain the relationship between inductively defined data types, recursive programs that process inputs of those data types, and inductive arguments about the correctness of those programs using induction over data types.
- Explain the difference between static and dynamic scoping rules in programming languages, and the use of environments and closures to realize these scoping rules, where appropriate.
- Explain parameter-passing mechanisms such call-by-value, call-by-result,
call-by-value-result, call-by-reference, call-by-name and call-by-need (lazy
evaluation); and be able to reason about the behavior of programs that use those
conventions.
- Explain what exceptions and exception handlers are, and what the rationale is for their scoping rules.
- Explain what a continuation is and what continuation-passing style is.
- Define type systems as inductive rule definitions, and reason about well-typedness of programs using those type systems.
- Explain the difference between type checking and type inference, and be able to derive inferred types for simple (ML-style) programs.
In order to provide the highest quality course, I am using material from the
course of Gary
Leavens
at Iowa State, with permission.
Additional material was also provided by Prof. Adriana Compagnoni, who in turn
credits Gary Leavens and John Hatcliff.
David Naumann
2006-12-08