Python vs. Perl, which is better to learn?

Chris chris at cmb-enterprises.com
Mon May 6 12:16:48 EDT 2002


In article <3CD623A7.4EE48B14 at engcorp.com>,
 Peter Hansen <peter at engcorp.com> wrote:

> Chris wrote:
> > 
> > In article <m3lmaxuacu.fsf at chvatal.cbbrowne.com>,
> >  Christopher Browne <cbbrowne at acm.org> wrote:
> > 
> > > Outside of that, I'd suggest that a lot of the problem comes from Perl
> > > having been a "hot, in-language" attracting a lot of bad programmers.
> > >
> > Exactly.  You can write bad code in any language.  On the other hand,
> > you can write really good, robust, readable, maintainable code in Perl.
> > 
> > Programming is about 99% concepts and 1% syntax, if that much even. A
> > poorly written Python program that can be easily read is still poorly
> > written.
> 
> More out of curiosity than an intention of starting a flame war, but
> would someone post a snippet of twenty or so lines of Perl which they
> believe is "readable"?
> 
> I've been looking at Ruby code in another group, and I can only assume
> that Ruby is considered even by Perl programmers to be more readable
> and "clean" than Perl.  I find it significantly less readable than
> Python however, so I would find the claim that Perl can be very readable
> to be a stretch.

You are essentially preaching to the choir.  :-)

I first learned Perl, then Python, which was a wonderful tool for 
helping me finally bend my mind around OOP concepts, and now I've come 
to prefer Ruby for being, at least in my experience, more predictable 
and flexible than Python.

That said, I've glanced over Haskell a bit in moments of boredom, and I 
think it's just possible that not having a background in functional 
programming is keeping me from enjoying some of the power of Python.

For what it's worth, Perl6 should improve things a great deal, with 
sigils having been re-examined, and with the reference/object issue 
resolved.  Additionally, subroutines and methods will be gaining named 
parameters, and optional strong typing.



More information about the Python-list mailing list