
12 Jan
2008
12 Jan
'08
6:16 p.m.
On Jan 12, 2008 10:54 PM, Henning Thielemann
On Sat, 12 Jan 2008, Hugh Perkins wrote:
I guess that Haskell's referential transparence means the answers to the isPerfectSquare will be cached, ie automatically memoized? (not sure if is correct term?)
Interesting... but I dont understand... I thought that referential transparence meant that once the answer to a function has been calculated once, it will always be the same, and that the interpreter can, and will, cache this answer? So, if I call f( 20 ) once, for some, arbitrary, f, it will have to go away and calculate f(20), but if I call it multiple times, it will just return the value it already calculated?