Thread: LLRnet enhancements View Single Post
 2008-03-26, 00:45 #2 kar_bon     Mar 2006 Germany 22×23×31 Posts here is another enhancement for LLRnet: insert the following red lines into 'llrnet.lua' (around line# 187, function 'Work()') and all found primes will be written in a seperate file called 'primes.txt': Code: (...) -- check user interruption if stopCheck() then return -- return with no error end end if result == 0 then local file = openfile("primes.txt", "a") write(file, format("%s %s\n", k, n)) closefile(file) end SemaWait(semaphore) -- add the result in tosend table and file local tbl = { t = t, k = k, n = n, (...) the primes in this file are formatted as one prime per line with 'k n' values. karsten