Brown trousers time :~

Ovid publiustemp-londonpm at
Mon Oct 8 10:24:18 BST 2007

--- "Lyle -" <perl at> wrote:

> Hi All,
>  Soon I'll be embarking on the largest project I've ever undertaken. 
> It's going to be 10's of thousands of lines of code. It needs to be 
> perfect (or damn close :))

Skipping most of the rest, what's of paramount importance is that your
code is both correct (does things right) and complete (does everything
it *must*).  That's the best place to start from when worrying about
optimization and there are plenty of well-established tools to help you
analyze your code's performance (from painful personal experience, most
programmers who try to guess up front what they need to optimize get it

So how do you ensure your code is both correct and complete?  It's
tough, but testing is one of the best ways to get close.  I'd recommend
the O'Reilly book "Perl Testing: A Developer's Notebook"
(  (disclaimer: I was
one of the reviewers, so I may be biased).  Once you learn to start
automated testing, so many other "hard" problems in programming become
so much easier.

Once you have a correct and complete system built, with tests, then you
can profile and optimize to your heart's content and feel much more
confident that you haven't broken anything.


Buy the book  -
Perl and CGI  -
Personal blog -
Tech blog     -

More information about the mailing list