[email protected]
[Top] [All Lists]

[Haskell-cafe] Re: FASTER primes (was: Re: Code and Perf. Data for Prime

Subject: [Haskell-cafe] Re: FASTER primes was: Re: Code and Perf. Data for Prime Finders (was: Genuine Eratosthenes sieve)
From: Will Ness
Date: Tue, 29 Dec 2009 03:49:34 +0000 UTC
Will Ness <will_n48 <at> yahoo.com> writes:

> 
> 
>   wheelSums  = roll 0 wdiffs
>   roll       = scanl (+)
>   wheel      = wdiffs ++ wheel
>   wdiffs     = 2:4:2:4:6:2:6:4:2:4:6:6:2:6:4:2:6:4:6:8:4:2:4:2:
>                4:8:6:4:6:2:4:6:2:6:6:4:2:4:6:2:6:4:2:4:2:10:2:10:wdiffs
> 

Apparently that works too, but I meant it to be:

   wdiffs     = 2:4:2:4:6:2:6:4:2:4:6:6:2:6:4:2:6:4:6:8:4:2:4:2:
                4:8:6:4:6:2:4:6:2:6:6:4:2:4:6:2:6:4:2:4:2:10:2:10:[]


:)


_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

<Prev in Thread] Current Thread [Next in Thread>