Login  Register

Re: Is lazy evaluation of infinite series possible?

Posted by HilaireFernandes on May 30, 2016; 1:23pm
URL: https://forum.world.st/Is-lazy-evaluation-of-infinite-series-possible-tp4897956p4898140.html

Did you take a look at Nicolai suggestion regarding the Generator class.
There is a fibonacci example in its test case.


fibo := GeneratorTest new fibonacciSequence

then to access the sequence term:
fibo next.

Hilaire
--
Dr. Geo
http://drgeo.eu