SIGCSE 2005 Session on Concepts-based Teaching of Programming

by Peter Van Roy

Birds of a Feather Session, SIGCSE 2005 Symposium

Thursday, Feb. 24, 2005, from 5:45 to 6:30 pm

Handouts: PDF, PowerPoint

We propose to teach computer programming in terms of programming concepts, not programming languages or paradigms. Starting with a small set of concepts, we add concepts one by one. Each concept is added exactly when it is needed, namely to overcome a limitation in expressiveness. We end up covering all the major programming paradigms and most concepts used in programming today. In this session, we would like to talk with people who are interested in this approach or who have taught with a similar approach. We will explain the approach and present some of the courses we have taught with it. We will answer any questions you may have about the approach.

The concepts-based approach is important because the current trend in programming education is to focus almost exclusively on tools and languages that are perceived as useful for industry. This means that the teaching of computer programming is limited to (mostly sequential) object-oriented programming in one or a few languages (e.g., Java). This is so despite the fact that there are dozens of tools and languages used in industry, covering many different techniques and programming paradigms.

One of the casualties of this trend is concurrent programming. Since concurrency is both complicated and expensive in Java, students get the mistaken impression that it is always so. The concepts-based approach, as we have realized it, explains easier and cheaper forms of concurrency such as dataflow and message-passing concurrency. The approach shows that they are better defaults for program structure than the usual shared-state concurrency of Java-like languages. They make it easier to write robust, secure, and extensible software. For example, Ericsson and other companies have long used message-passing architectures for building robust telecommunications systems. Our approach extends previous approaches based on concepts, e.g., using "Structure and Interpretation of Computer Programs" or the Leda multi-paradigm programming language, which give little attention to concurrency.

In our experience, the concepts-based approach is the most efficient way to teach all the relevant techniques and paradigms. This is because each concept is introduced just once, in its proper place. Two paradigms that differ in only one concept are presented next to each other, so that only the difference has to be explained. This avoids duplication of effort and gives the student a uniform framework for thinking about programming.

We have been teaching with the concepts-based approach since 2001. We have published a textbook with MIT Press in March 2004, "Concepts, Techniques, and Models of Computer Programming", which is now in its second printing. This textbook was four years in the making. It gives our latest understanding of the discipline of programming, explained in a simple and precise way. We use a high-quality open source software platform, the Mozart Programming System, that can run all the examples in the book. We make available complete course material on the textbook's Web site. In fact, the hardest part of using our approach is getting used to all the new ideas it contains. We think it brings the excitement back to teaching programming.

Our version of the concepts-based approach is already being used in second-year through graduate courses for CS majors in a dozen major universities worldwide, including:

These universities recognized the value of the concepts-based approach early on and appreciate how we have developed it. The approach is based on more than a decade of research by an international group of researchers, the Mozart Consortium. It distills our experience in understanding programming and how to teach it.