zathras at thwackety.com
Sat Jun 12 21:52:52 CEST 2004
On Sat, 12 Jun 2004, Jens Thiede wrote:
> I'd like to know what other people think about Python. In particular, what
> is Python best suited for?
Programs you want to get done, run at a reasonable speed with clear places
and routes for optimisation should that _need_ to happen, and have fun
along the way.
In more concrete terms, I would take this to mean data rich applications
using databases, algorithmic rich applications (eg analytic/simulation
systems), network servers (twisted is one of the best event based
frameworks (*) I've seen), GUI applications, and writing games.
(*) By contrast, Perl's POE is one of the most hideous systems I've ever
worked with (despite how well it does actually work), and no C++
event based framework I've looked at has ever looked pleasant to work
> Could anyone comment on how Python fares against C++, Java and Perl?
I'm not going to compare against Java/C++, but with reference to perl,
having written programs almost day in day out for 5 years in perl before
coming to python I would say that they're comparable languages. For
programs that require *lots* of string transformation, perl is a more
natural fit IME, but for many, many, many other projetcs, I've found
python to not just be a better fit, but a more enjoyable fit.
One observation regarding perl/python have over C++/Java is the lack of
compile cycle generally results IME with more people writing unit tests,
and distributing unit tests with their code. Make of that what you will -
IMO it's a _very_ positive plus for both languages. For a highly trustable
opinion on C++/Java vs python/etc I would suggest looking for the
interviews with people like Bruce Eckel on his thoughts on the matter.
One final point I feel though - python strikes me as a having a greater
likelyhood at being maintainable. Perl often tends to become more and more
obfuscated with time. The edit/compile/test cycle of Java/C++ IME often
leads to greater chance of awkward to find/fix errors occuring. In
contrast, the heavily used python idiom of ' if __name__ == "__main__": '
tends to lead to a modularity I've not personally seen in many other
Bearing in mind that a lot of code is maintained by people who weren't the
original developers... Given that 90% programmers aren't in the 10% of
best programmer rankings, this strikes me as a good thing. Given that 90%
of programmers tend to think they're in the top 10% anyway and will use
features they don't really understand properly, using a language which is
geared well towards maintainability strikes me as a strong positive.
More information about the Python-list