Hi Bulat,
that is so cool!
Günther
Bulat Ziganshin schrieb:
Hello Gü?nther,
Friday, March 27, 2009, 11:30:41 PM, you wrote:
Some of the memoizing functions, they actually remember stuff
*between* calls?
what i've seen in haskell - functions relying on lazy datastructures
that ensure
It seems there is a very close correspondence between data structures and
functions in Haskell. Your powersOfTwo function, since it gets memoized
automatically (is this the case for all functions of zero arguments?), seems
exactly like a data structure. This harks back to my Scheme days when we
On Fri, 2009-03-27 at 14:26 -0700, Kirk Martinez wrote:
Your powersOfTwo function, since it gets memoized automatically (is
this the case for all functions of zero arguments?),
It is the case for all functions which have zero arguments *at the time
they are presented to the code generator*.
2009/3/27 Kirk Martinez kirk.marti...@gmail.com:
It seems there is a very close correspondence between data structures and
functions in Haskell. Your powersOfTwo function, since it gets memoized
automatically (is this the case for all functions of zero arguments?), seems
exactly like a data
2009/3/27 Kirk Martinez kirk.marti...@gmail.com:
I wonder: does the converse exist? Haskell data constructors which are
really functions? How and for what might one use those?
You might enjoy reading about the use of tries for memoisation. Conal
Elliott explains nicely how you can an
Hi Dan,
yep, I've come across that one too and wouldn't you know it, the by now
infamous Luke Palmer has left an interesting insight on that blog too :).
So I reckon here the cycle closes.
Günther
Dan Piponi schrieb:
2009/3/27 Kirk Martinez kirk.marti...@gmail.com:
I wonder: does the
Kirk Martinez wrote:
It seems there is a very close correspondence between data structures
and functions in Haskell. Your powersOfTwo function, since it gets
memoized automatically (is this the case for all functions of zero
arguments?), seems exactly like a data structure. This harks back