September 2017
Beginner to intermediate
396 pages
9h 46m
English
The preceding algorithm is inspired by Richard Bird's list-based algorithm for the sieve. The algorithm carefully uses laziness, recursion, and infinite lists to create an infinite list of prime numbers. The following diagram will help you visualize the algorithm:

In the implementation, we carry out following steps:
Read now
Unlock full access