| | |
Summary: Using simulation in an objectsearly approach to CS1 and CS2
Owen Astrachan
Duke University
ola@cs.duke.edu
Claire Bono
University of Southern California
bono@usc.edu
(listed alphabetically)
Abstract
Our philosophy is that CS1/CS2 students learn best as apprentices, by studying the work of more
experienced program designers and writers and by extending and modifying programs provided by these
experienced programmers. Objectoriented programming supports this philosophy well and permits
our students to explore a realm of programs not possible using a more traditional ``structured'' ap
proach. Our approach emphasizes using objects before creating them, reading and modifying programs
before designing them. Although our philosophy transcends a particular objectoriented language, we
have chosen C++ for our courses; our approach facilitates its use by novices. In this paper we discuss
our approach, and suggest simulation as a rich area for case studies, labs, and assignments when em
ploying this objects early approach. We provide details of two simulations we have used in our courses:
a simulation of the card game war and a queueing simulation.
1 Introduction
|