"S.D.Mechveliani" wrote:
> Suggestion for standard library:
> --------------------------------
> to remove the names minimum(By), maximum(By)
> and to make min(By), max(By), gcd, lcm
> for the lists only.
> For example,
> min [x,y], min [x,y,x,u], minBy compare [x,y,x,u]
>
> gcd [4,6], gcd [4,6,4], gcd [4]
>
> This is for the economy of function names. Less names to recall.
Hmm. I agree in principle with eliminating redundant functions, but
where is the line drawn? Should we eliminate all basic functions where
there is a fold-based equivalent? At the extreme, do we abandon (+)
because we have sum? (*) for product? (&&) for and? (++) for concat?
I'm sure there are many others. AFAIK, just about every time we have a
function in the library that can be defined in terms of fold[lr], we
also have the corresponding rudimentary function available.
Matt Harden
[EMAIL PROTECTED]