[m-rev.] New library module: pile

Fergus Henderson fjh at cs.mu.OZ.AU
Wed Feb 12 20:03:59 AEDT 2003


On 12-Feb-2003, Peter Moulder <pmoulder at csse.monash.edu.au> wrote:
> On Wed, Feb 12, 2003 at 05:07:41PM +1100, Ralph Becket wrote:
> > +    % length(T) = list.length(list(T))
> > +    % An O(n) operation.
> 
> Perhaps `Theta(n)' or `\Theta(n)' ?  array.length is O(n) too, taking
> a traditional mathematical interpretation of big O.

The library reference manual should not forbid implementations from
running faster.  Optimizations such as deforestation and partial
evaluation mean that there is never any lower bound, so using Theta(...)
notation here would not be correct.  O(...) notation is the right one
to use here.

P.S.
I agree with your other review comments, which were excellent -- thanks.

-- 
Fergus Henderson <fjh at cs.mu.oz.au>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list