On 19-07-11 00:44, Maciek Godek wrote:
> I also think that functional programming perhaps seems to make little sense
> in a small scale, but as your programs grow large, it becomes increasingly
> important.
Maciek,
You know, I think you might be right and I think this might be at the
root of my
On 19-07-11 09:31, James Geddes wrote:
> Indeed, I would have thought that the calculation time would be
> entirely dominated by the test for primality, and especially what
> happens once the candidate primes are bigger than 2^64 and can no
> longer be represented by a single word.
James,
I assum
On 19-07-10 02:46, Maciek Godek wrote:
> A while ago, I wrote a booklet which used almost the same problem to
> introduce to, what you called nicely in the title of this thread, "thinking
> in Scheme", so if you're interested, you may want to check out the first
> chapter ("Introduction"):
Maci
Daniel,
Thank you.
The piece of the puzzle I was missing was in-value.
Your version is much easier to read than mine. It is also easy to
modify it to get a list of the primes that occur, which is nice.
Regards,
Bob
--
You received this message because you are subscribed to the Google Groups
ound)
; Primes of the form 2^n+3
(count-primes-in-seq
(λ (n) (+ (expt 2 n) 3))
bound)
Regards,
Bob Heffernan
--
You received this message because you are subscribed to the Google Groups
"Racket Users" group.
To unsubscribe from this group and stop receiving emails from
On 18-08-16 11:43, 'Paulo Matos' via Racket Users wrote:
> I really, really don't like nesting and a few years ago adopted the
> style of internal defines. It makes for much more readable code:
>
> (define (foo x)
> (define y (f x))
> (define z (g y))
> (define p (h z))
>
> (bar p))
Than
uot;. On the other hand, it
often helps readability.
It might be, of course, that both versions amount to the same thing
after the interpreter has been at them.
Thanks and regards,
Bob Heffernan
--
You received this message because you are subscribed to the Google Groups
"Racket Users&quo
7 matches
Mail list logo