Lazy Evaluation Flashcards
1
Q
What is lazy evaluation?
A
A lazy function programming language evaluates the arguments of functions and of constructors only when necessary to give a result and then only as far as necessary to give a result.
2
Q
When would this be used?
A
With infinite lists i.e. to return a list of primes