ABSTRACT
In today's business climate, reusable code is essential. But many programmers often don't use existing utility functions because they find them difficult to use or not general enough. Also, they may not know that such functions exist. Instead, programmers often clone lines of code from other functions. This results in sloppy, undocumented code which is full of errors. In order to avoid this, the author of a utility function must make an extra effort to ensure that his function is designed properly.APL is easy to learn because its primitives behave consistently, work on arrays as well as scalars, can handle edge conditions, often use default values and are totally encapsulated from the user. We can learn from this by designing utility functions in the same way, allowing them to become an extension of APL and its set of primitives. This paper will show some examples and design techniques.
- {Man89} Mansour, Stephen, "Techniques for Avoiding Conditional Execute in APL2," APL89 Conference Proceedings, APL Quote Quad, Vol. 19, no. 4, August 1989.Google Scholar
- {Man93} Mansour, Stephen, "Using Defined Operators and Functions Arrays to Solve Non-Linear Equations in APL2," APL93 Conference Proceedings, APL Quote Quad, Vol. 24, no. 1, August 1993.Google Scholar
Index Terms
- How to write an APL utility function
Recommendations
How to write an APL utility function
In today's business climate, reusable code is essential. But many programmers often don't use existing utility functions because they find them difficult to use or not general enough. Also, they may not know that such functions exist. Instead, ...
APL function editing in APL
APL '76: Proceedings of the eighth international conference on APLMost of the present APL systems available provide only the del form definition for function entry and revision. However, I have often found this conventional editing facility awkward and slow to use. For more convenient revision I prepared a number of ...
Style and literacy in APL
… then the strut changed to the restless walk of a caged madman, then he whirled, and to a clash of cymbals in the orchestra and a cry of terror (perhaps faked) in the gallery, Mascodagama turned over in the air and stood on his head. —Nabokov, Ada “See ...
Comments