[Haskell-cafe] Shouldnt this be lazy too?

Andrew Coppin andrewcoppin at btinternet.com
Mon Sep 24 15:36:03 EDT 2007


Jonathan Cast wrote:
> On Mon, 2007-09-24 at 17:35 +0100, Andrew Coppin wrote:
>   
>>>       
>> In an ideal world, yes.
>>
>> In this world, use "length (take 11 [1..]) > 10"...
>>     
>
> not (null (drop 10 [1..])) is surely faster (not tested...)
>   

Faster? There might be a few microseconds in it.

Clearer? Possibly... ;-)



More information about the Haskell-Cafe mailing list