Random Prime Generator/Modular Arithmetic
stanc at al.com.au
Sun Mar 5 16:07:20 CET 2006
Also you last code which looked like:
what does s2num do? im assuming it changes string chars to ascii
decimal? Is that correct?
and i thought is_prime would work better if you listed all small primes
(<20000) and check if they are divisible by those.
Aside from that Im really interested in your cran_rand function as I
havent fully tested it out yet.
>Hmmmm. Well, I don't know what else I could do, except for to write a
>function that doesn't require recursion. Still, 300 digits isn't too
>bad... I have also realized that if you try is_prime(3) it will return
>false. I'll have to work on it... Thanks for the help!
More information about the Python-list