6 lines
177 B
Text
6 lines
177 B
Text
count:=0;
|
|
foreach n in ([1..10_000]){ // yes, this is sloooow
|
|
count+=isPrime(n);
|
|
if(n==100 or n==1000 or n==10_000)
|
|
println("Primes <= %,6d : %,5d".fmt(n,count));
|
|
}
|