APL THINKING: EXAMPLES Murray Eisenberg Mathematics h Statistics Dept. University of Massachusetts Amherst, MA 01003 IJSA (413) 545 - 2859 Abstract In an effort to understand ‘APL thinking”, we examine a few selected examples of using APL to solve specific problems, namely: compute the median of a numerical vector; simulate the Replicate function; string search: carry forward work-to-be-done in excess of capacity: rotate concentric rectangular rings in a matrix: find column indices of pivots in an echelon matrix. These examples are drawn from our teaching experience as well as from APL literature. We are particularly interested in studyinq thinking processes underlying alternative solutions to such problems -- i.e., our goal is to ‘get inside the head” of the APL programmer, Analyses include rWXnStrUCtin9 thoughts, comparing alternative approaches, and, in general, scrutinizing supposed characteristics of APL thinking. Introduction Is there such a thing as “APL thinking”? If so, what is it? When a programmer claims to solve a problem in an ‘APL way’, We must ask what is meant by that. And, when someone implies that the APL way is better, or that APL is a better language for thinking about problems, we must ask how APL helps (or hinders) problem-solving. Specifically, just what is unique of special or different about thinking with APL? Such questions motivate us to study how APL affects cognitive processes. This should enable us to teach APL more effectively and to promulgate its advantages. In an effort to understand “APL thinking”, we began by focussing on views within the Permission lo copy wilhoul fee all or par1 ol’ Ihis malcrial is granlcd provided that the copies arc IIOI made OI- distributed I’or dirccl commercial advankrge, thc ACM copyrighl notice and the tilk ot the publication and ils date appear, and nokc’ is given thal copying is by permission ol’ the Asocialion t’or C’omputing Machinery. ‘1’0 copy olhcrwisc, or IO republish, rcquirrh ii I’cc and/or spc