NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.
All the Perl that's Practical to Extract and Report
Stories, comments, journals, and other submissions on use Perl; are Copyright 1998-2006, their respective owners.
How Often Do You Need This? (Score:2)
My question for Java developers is always the same: can you, without looking at the docs, write the code to open a file, read the first line from the file (delimited by a newline) and print said line? The answer is invariably "no, but ...".
The counter-argument is that since they don't need to do this very often, there's no need to optimize this. When you're working in an "enterprise" environment, you're not constantly opening and reading files. Just to prove this point, I ran this on our codebase here:
Hmm, that shows six modules. Further investigation shows that we open files seven times (actually, a bit more as that's a naïve regex). So maybe opening and reading files is common?
Or maybe, as I suspect, since it's so easy in Perl, we reach for it more.
Reply to This
Re: (Score:2)