ABSTRACT

This chapter describes an amorphous collection of techniques, variously called agenda-based control, queue-based control, streams, generated lists, coroutines, and possibilities lists. A process can run for a while, and then suspend itself until the main loop decides to try it again. The term coroutine is also used for members of a set of processes, all but one of which are suspended at any given time. A board position will be a data structure representing who is on which bank of the river; it will also have a slot POSITION-PATH which tells how the position was arrived at. In older Lisps with dynamic variable bindings, this is the appropriate data structure for nodes. One could define nodes to have three elements: a score, a sprouting function, and a list of arguments to pass to the sprouting function.