2 May 2003 09:03
Re: [stack] Patterns, recursion combinators and a programming challenge
<phimvt <at> lurac.latrobe.edu.au>
2003-05-02 07:03:23 GMT
2003-05-02 07:03:23 GMT
On Mon, 28 Apr 2003, Nick Forde wrote: > phimvt <at> lurac.latrobe.edu.au writes: > > Thanks for that. My response to the pattern movement had been > > tepid until now, but after your mail I might well have another look. > > When I first read about design patterns I wasn't particularly > impressed as they didn't really give me any new insights into OO > design. I'd encountered many of the patterns over the years and the > books seemed to only offer labels for patterns already in common use. > > In hindsight I was missing the point. Naming these patterns IS their > benefit. Yes, that is the conclusion I reached when writing my previous note. The "structured flow of control" patterns IF, WHILE, REPEAT, CASE LOOP-and-a-half (with single exit somewhere) are useful, common, descriptive and adequate almost everywhere. Similarly the various recursion patterns for lists MAP FOLD FILTER, and I suspect the other more general recursion patterns are useful, common, descriptibe and adequate almost everywhere. What goes on in the mind of programmers I do not know, but having found the right (common) pattern, it helps to give it a name. It also helps future maintainers to "see the pattern" as fast as they can read its name. > patterns to be a useful level of abstraction above objects. Of course > ideally programmers wouldn't need patterns as they could be considered(Continue reading)
4. Returns a real function, meaning something that you can use
wherever you could use a function you had defined in the
ordinary way in the text of your program.
RSS Feed