Bringing algorithms to life

John Sigle · 1987

Static presentations of algorithmic behavior, as in textbooks and on the chalkboard, are often difficult and very time consuming to produce and sometimes fail to convey the true nature of the process. It is desirable to have a dynamic (animated) presentation of the algorithm going through its paces on an actual example. Tracing facilities provide some aids for following the progress of a program but generally do not provide a neat, easy to follow presentation of the process. This article presents a systematic approach to augmenting the code of a program so that it becomes self-illustrating. When this augmented code is run it renders the algorithmic behavior highly visible. Two versions of this approach are presented. The first, and simpler, shows the data being manipulated by the algorithm; the second additionally shows the program going through its paces.

Read the paper · More papers on PaperTik