sieve.l (312B)
1 # 25feb10abu 2 # (c) Software Lab. Alexander Burger 3 4 # Sieve of Eratosthenes 5 (de sieve (N) 6 (let Sieve (range 1 N) 7 (set Sieve) 8 (for I (cdr Sieve) 9 (when I 10 (for (S (nth Sieve (* I I)) S (nth (cdr S) I)) 11 (set S) ) ) ) 12 (filter bool Sieve) ) ) 13 14 # vi:et:ts=3:sw=3