On Oct 18, 2008, at 12:51 PM, Gerhard Fiedler wrote: > Does the "adequate size" of a Pascal function differ from the > "adequate size" of a Pascal procedure? Why? If not, why is the > distinction relevant in this context? Interesting question. I was going to point out that several of the Basics I've used DO have a specific implementation for functions that return mathematical values ("deffn"), and IIRC they were all restricted to functions of a single line (ie functions that LOOK like mathematical functions.) deffn polynomial(x) = x^3 - 3*x^2 + 2^x - 12 But I wasn't sure what "modern" basics did WRT subroutines/functions. The distinction (deffn vs "gosub") in those BASIC implmentations is a fine example of "old style thinking" for the two, including the many problems introduced by the "gosub" construct. (and, oh! the evil things that one did in fortran "subroutines" to get around enforced pass-by-value semantics. "Named common areas." Shudder.) Another thing that has blurred the distinction is subroutines that "return" multiple values by modifying their parameters. (And Pascal specifically allows this, right?) BillW -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist