Yes (and I did so, too, at start), but `compose' is too long a word (compare it to Haskell's `.'). So I've decided to name procedure constructors in a unified manner:I think that there's a nice tradition among the Scheme programmers to
use the name "compose" to refer to a composition function. It is much
more descriptive than "dollar-asterisk" ("multiply dollars"? "a
millionare marries a star"? "jackpot"?), and hence more
reader-friendly, and unless you are doing some domain-specific
research, your programs usually won't get much longer because of that.
So that's a rule: when (filter) is fed with one list, it returns one list. When it's fed with several lists, it returns as many lists.
As to the behaviour of "filter", it is not clear whether it should
behave as you described when more than one list is provided. Perhaps
it should rather iterate over their cartesian product? Or concatenate
the lists? That's one more thing to remember, and eventually one more
thing to forget. If you're doing something complex, don't let your
code pretend that it's something simple.
_______________________________________________ Scheme-reports mailing list Scheme-reports@x http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports