Hi Franz, if you need higher precision for just one clause, revert precision back to the default in the next clause, using NUMERIC DIGITS.
To really speed up calculating a list of primes, use the Sieve of Eratosthenes, which will be faster by several magnitudes. ~~~ -- sieve use strict arg n = 2015177 prime = .Array~new(n)~fill(.true)~~remove(1) do i = 2 to sqrt(n) if prime[i] = .true then do j = i * i to n by i prime~remove(j) end end primes = prime~allIndexes say primes~items "primes up to" n say primes~section(1, 20)~makeString(, " ") "..." say "..." primes~section(primes~items - 20)~makeString(, " ") ::routine sqrt public external "library rxmath RxCalcSqrt" ~~~
_______________________________________________ Oorexx-devel mailing list Oorexx-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/oorexx-devel