develooper Front page | perl.perl6.language | Postings from June 2005

Re: reduce metaoperator on an empty list

Thread Previous | Thread Next
From:
Michele Dondi
Date:
June 1, 2005 05:17
Subject:
Re: reduce metaoperator on an empty list
Message ID:
Pine.LNX.4.62.0506011226530.6692@kirk.pcteor1.mi.infn.it
On Wed, 1 Jun 2005, Luke Palmer wrote:

>    $ordered = [<] @array;
>
> If @array is empty, is $ordered supposed to be true or false?   It
> certainly shouldn't be anything but those two, because < is a boolean
> operator.

I read that (mathematically) as "for all i, for all j such that j-i=1,
a_i<a_j", which is certainly satisfied by an empty list.


Michele
-- 
> Why should I read the fucking manual? I know how to fuck!
In fact the problem is that the fucking manual only gives you 
theoretical knowledge which is useless in practice ;)
- Giuseppe "Oblomov" Bilotta in a bunch of usenet groups.

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About