Skip to main content

Neal Ford: Functional thinking: Laziness, Part 2

Functional thinking: Laziness, Part 2: Implementing lazy evaluation is easy in a language that supports closures. This Functional thinking installment shows how to derive a lazy list using Groovy's closures as building blocks. Then it explores some of the performance and conceptual benefits of lazy evaluation, including the ability to initialize fields lazily in some languages...

Community: General