Bulletin of Applied Computing and Information Technology

Home | Issue Index | About BACIT

Todd Cochrane, Wellington Institute of Technology, New Zealand
todd.cochrane@weltec.ac.nz

 Cochrane, T. (2006, July), A Workshop with Alice. Bulletin of Applied Computing and Information Technology Vol. 4, Issue 1. ISSN 1176-4120. Retrieved from

1. INTRODUCTION

The workshop with Alice brought a number of Polytechnic teachers out of their summer haze and into a possible alternate Universe in which computer programming is introduced to young children as a way to tell stories in 3D virtual worlds. Dr Barbara Boucher Owens (Barbara) lead a workshop that revealed details of Alice and its potential as an instructional tool, gathered feedback on Alice and touched on an idea that might lead to a solution to "a Problem with CS1 (Computer Science 1)".

This problem is that we have to add Object Oriented Pogramming (OOP) concepts to an already full set of learning outcomes for the set time given to to be delivered. A decrease in student participation in introductory Computer Science (CS) courses and their relatively low success rate in subsequent programming courses is also a well-known issue that could possibly be called "the Problem with CS".

Barbara is particularly interested in understanding how female students become interested, participate and succeed in CS courses.  She is at present on sabbatical from her role as Associate Professor of Computer Science at Southwestern University in Austin, Texas (USA). As Vice-chair of the ACM SIGCSE (Special Interest Group in Computer Science Education) and having been a member since 1968, I imagine that she also acts as a shepherd in CS education. Her practical "I'll show you how" teaching method reflects a wealth of experience in the classroom that made the workshop productive and fun.

So, how does Alice work? The answer is - by providing an environment in which an approach to programming can be taken that uses a blend of traditional problem solving techniques, storyboards, program visualization and high impact motivation (using 3D graphics and animation). Alice helped at-risk students who participated in a "two year proof of concept study" carried out at Saint Joseph's University and Ithaca Community College. Students who took an Alice class prior to CS1 received a B on average; 88% of these went on to CS2. Those who did not take an Alice class gained a C on average; 47% of these students went on to CS2.

2. THE WORKSHOP

The workshop was presented as a sequence of presentations followed by practice. Here is Alice, as I see it, based on the workshop (any aberrations, misunderstanding or misinterpretations are mine). In fact, problem solving in Alice reflects traditional problem solving, as shown by the steps described below.

"Read and understand the problem or task specification" is undertaken in Alice by "reading and understanding a scenario - tell a story, play a game, carry out a task". A 'world' is set up that corresponds with the story being told.

"Design a Solution" is undertaken in Alice by designing storyboards. Storyboards can be drawn up that indicate the elements (objects or assets) of each part of the story. An initial scene for the story's 'World' is set up directly in Alice. Alice comes with a number of 3D world templates, for example "Space". Objects are added to the scene by moving to an "Add Objects" mode. Items are added from a library of objects installed along with Alice. More objects can be accessed through the web. During "Add Objects" mode items can be added to, selected and positioned in a 3D Scene, textures can be added to object’s surfaces, and the view of the scene can be switched from a 3D projection to a "Quad" view showing: top, left, bottom and right views of the scene.

"Implementation" is undertaken in Alice by using a "drag and drop" editor that allows construction of a program. Once objects have been added to the scene, you switch back into programming mode by selecting "Done" in "Add Objects" mode. Programs start at an event handler that runs "when the 'world' starts". You add methods to the 'World' or to individual objects. Methods of objects will only run in Alice if they can be reached from the "when world starts" event handler. A "part-of" hierarchy of objects starting from the World and going into the parts of object in the 'world' is depicted as a tree similar to the object navigator trees in other Integrated Development Environments ( IDEs) or to the directory tree of the Windows Explorer or the Mac Finder. Clicking on the object in the 3D World selects the object and presents the methods, properties and functions defined for that object. Statements are constructed by dragging methods in to an area representing the method under development. This area has a set of tabs showing methods (and event handlers) that are being edited.

New methods, functions and properties can be added to an object by clicking an "Add new ???" button. The editor "automagically" lays out a statement template when a property, method or function is dropped into the tab representing a particular method or event. The statements containing references to  methods are ordinary sub-routine or method call statements. Functions are placed as expected, in place of expressions of the correct type. 

Apart from statements that use domain specific methods and functions, for example "objectA turn towards objectB", Alice provides the standard set of structured programming statements: if-else and various types of loops. All these are represented as a "docked window" or box that contains blocks of statements. Statements are dropped into areas that highlight as you move over them. These boxes expand as you add a statement to them. Any statement or expression can be dragged on to and off a "clipboard" (which looks like a clipboard) at the top right of the editor. Statements can be deleted by dropping them in a rubbish bin. "Undo" and "Redo" can be achieved by clicking on the icons representing these editing commands. "Copy”, "Paste” and "Delete" are available through keystrokes, as expected, and in a pop-up context menu.

Unlike entirely sequential programming languages, Alice introduces a "Do together" statement that specifies concurrent execution of statements within its block. A corresponding "Do In Order" overrides concurrent execution for all statements in its block. This took me a bit to come to terms with. I was wondering why a number of the built-in methods contained one infinite loop into which all other statements were placed. It took me a while, but of course, in the end, I "got it". These methods were designed only to be called in a "Do Together" block! "Hurray!"I thought when this revelation came through.

Alice provides Real, Integer, Boolean, String, Object, List and Array as part of the definition of a value. Someone has also undertaken some work with the visualization of Objects, Lists and Arrays. I have not found out how to program the creation of a object, i.e. write a constructor and call it for a class. It seems that all classes are "prebuilt". Adding an object to the world is described as "adding an instance of a class" by Alice. Maths objects and other useful objects are found by exploring the "world" in Alice's object explorer - not to be confused with exploring the virtual "world".

"Testing" is undertaken in Alice by running the script you have written. Statements can be disabled and there are ways to write comments. I did not find a way to inspect values or to run the code step by step. So testing and debugging might need a bit of careful management. The main focus for Alice is the ability to iterate quickly and hence identify changes and modulate your design.

Making your own objects requires a package like 3DS Studio Max or Maya, although you can get hold of a "person builder' on line, which lets you create people for your world.

Thank you very much to Barbara Boucher Owens, for the Alice workshop. It really increased my understanding of the Alice programming language. It helped me understand more about how to apply a consistent metaphor in the design of a visually oriented "direct-manipulation" programming system. It also added value and depth in the motivation of my current project within HyperPascal.

Further information about Alice is available from www.alice.org. .Alice and the source code are free to download. Tutorial material and supplementary material for a textbook: “Learning to Program with Alice” by Wanda Dann, Stephen Cooper, and Randy Pausch, can be found at www.aliceprogramming.net.

3. ACKNOWLEDGEMENT

This report contains a number of comments from Barbara 's slides:

Owens, B. B (2006, January 26), Programming With Alice 2.0. Presented at a Workshop on Working with Alice, UNITEC, Auckland.

Home | Issue Index | About BACIT