    primes :- list of all prime numbers generated by the
              Sieve of Eratosthenes, say
              primes?
              to list them until space runs out or e.g.
              take 1000 primes
              This program first appeared in the 1976 SASL manual;
    primes = sieve [2..]

    sieve (p:x) = p:sieve {n|n<-x;n % p > 0}
