A Note to Instructors about Karel J. Robot

 

This version deviates from the original Karel books in two ways. There is a new Chapter 4 on polymorphism before the introduction to IF and WHILE statements (now Ch 5). This is due to the central position of polymorphism in object-oriented programming. The hope is that by introducing it early and giving it some reinforcement, the students will think of this before they think of IF statements when they need to produce different kinds of behavior. If you yourself learned procedural programming in Pascal like languages, this lesson may be harder for you to learn than it will be for them.

There is additional material on polymorphism at the end of Chapter 5.

The book also goes beyond the original 6 chapters by introducing material on concurrency as well as an introduction to the rest of Java. Chapter 11 is rather speculative, however, as I was experimenting with some advanced ideas. I'm not sure that it is quite right yet.

More material may be added in the future.

I'd be happy for any feedback on this--especially feedback from those who have used it in the classroom.

If you want to use this manuscript and its simulator in your own teaching, we ask that you have a few copies of the printed Karel ++ text available for your students -- say one for every three students. This will give them access to the exercises and will also serve to repay the authors and publisher for our efforts.

 

There has been a recent change in the language. The directions used to be an int. Now they are elements of a class: Direction. You still implement Directions (plural) but the direction parameter to a constructor has type Direction (singular). Its values are still North, South, East, and West.