3 ms·
Aside from streams, infinite sequences can also be represented as functions from the natural numbers to the element type.
by xigoi 4y ago
Aside from streams, infinite sequences can also be represented as functions from the natural numbers to the element type.
- qsort 4y agoOr, better yet if your language supports it, coroutines/generators/continuations.