Sieve of Eratosthenes: Difference between revisions
Content deleted Content added
Added Euler |
|||
Line 5,757:
max = sqrt len is_divisible[]
for d = 2 to max
if is_divisible[d] = 0
for i = d * d step d to len is_divisible[]
is_divisible[i] = 1
.
.
.
for i = 2 to len is_divisible[]
if is_divisible[i] = 0
print i
.
.</syntaxhighlight>▼
▲</syntaxhighlight>
=={{header|eC}}==
|