A little advice please? (Convert my boss to Python)

Peter Hansen peter at engcorp.com
Mon Apr 15 22:21:47 EDT 2002


Duncan Smith wrote:
> 
> My boss is considering moving to Python (from Poplog), so I've coded up
> something to read in records from a text file (as below) and return a
> statistic based on the numbers of unique and paired records (as he
> requested).  Easy enough (code below), but now he wants to compare it for
> speed against some existing code (Poplog?).  

As another "boss", I want to make the strong point that speed 
is not what Python is about (although you may well make this
fast enough to suit him... it's not necessarily slow).

Python provides exceptional benefits in the areas of development
time, readability and therefore code maintenance, flexibility,
reliability, and ease of learning.

If he concludes that it's not "fast enough", I suspect he
is focusing too much on a relatively unimportant issue 
and likely to miss out on a some major competitive advantages.

Most of the time when someone concludes Python is not fast
enough, they have a situation where something is expected
to run once or twice a day, and it might take ten minutes
with Python and one minute with C, and they conclude that
is too slow...  meanwhile the C version is buggy, took 
four times longer to develop, and nobody likes to maintain
it because the code is five times longer than the Python
one would be.  

So make sure he takes a good hard look at just how much
speed he really _needs_ (not wants), and at the places
where Python really shines, before closing the door on
your suggestion.

(For what it's worth, we've more or less outlawed 
any internal tools not written in Python as being a 
waste of the developer's time, and NONE of our utilities
are "too slow".  (No, we're not quite as anal about it
as that sounds, but you get the point.))

-Peter



More information about the Python-list mailing list