Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Re^3: Project Euler (a series of challenging mathematical/computer programming problems)by radiantmatrix (Parson) |
on Feb 07, 2006 at 16:04 UTC ( [id://528546]=note: print w/replies, xml ) | Need Help?? |
No need to reformat, just use the script below to put the large primes file in a DBD::SQLite2 database. First, download and unzip the files that contain the first 15 million primes in chunks of 1 million. You will have primes1.txt through primes15.txt in a directory. Run this there:
Then you can always ask for the n'th prime with the SQL (? is n)
<-radiant.matrix->
A collection of thoughts and links from the minds of geeks The Code that can be seen is not the true Code I haven't found a problem yet that can't be solved by a well-placed trebuchet
In Section
Meditations
|
|