]> git.rkrishnan.org Git - sicp.git/blob - src/sicp/ex4_29.rkt
Solutions to 4.27, 4.28 and 4.29.
[sicp.git] / src / sicp / ex4_29.rkt
1 #lang racket
2
3 #|
4
5 Any program which will call itself or another function recursively or repeatedly (as another argument) 
6 will benefit from memoization.
7
8 non-memoized version will have count of 2 as x gets forced twice in the expression (* x x). In memoized
9 version, it will be 1.
10
11 |#