Big primes by sjoerd_visscher

main=mapM print$take 100[z|z<-[32416187567..],z#p>0]
n#(p:q)|p*p>n=n|n`mod`p>0=n#q
_#_=0
p=2:p![3..]where(p:q)!r=h++q![x|x<-t,x`mod`p>0]where(h,t)=span(<p*p)r

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page