in reply to Reading files too slow

If you'rr re-reading files during a single run, and the files are smallish (say <= 50k average ), then it might makes sense to slurp (read the entire file as a single string) them into an array or hash. 10k * 50k == 500MB, which is well with the reach of most machines these days.


Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
"Science is about questioning the status quo. Questioning authority".
In the absence of evidence, opinion is indistinguishable from prejudice.
"Too many [] have been sedated by an oppressive environment of political correctness and risk aversion."