Why use Perl when we've got Python?!

John W. Stevens jstevens at basho.fc.hp.com
Sat Aug 14 05:02:38 CEST 1999


> In comp.lang.perl.misc, 
>     "John W. Stevens" <jstevens at basho.fc.hp.com> writes:
> :> Likewise, because an array and a hash
> :> are, despite their interconvertibility, fundamentally different things,
> :> they *look* different.  Contrast Python's:
> :> 
> :>     b = ["alpha", "beta", "gamma"]
> :>     c = { "fred" : "wilma", "barney" : "betty" }
> :>     print "b nought is", b[0]
> :>     print "c fred is", c["fred"]
> :> 
> :> with Perl's
> :> 
> :>     @b = ("alpha", "beta", "gamma");
> :>     %c = ( "fred", "wilma", "barney", "betty");
> :>     print "b nought is", $b[0];
> :>     print "c fred is", $c{"fred"};
> :
> :Correct.  Python's behavior is preferable.  Think: operator overloading
> :in C++.
> 
> You seem to equate quantifiable benefit with mere opinion.  Please work
> on that.

And you have a tendency to jump to conclusions.  The benefits are
quantifiable.  They are not opinion.  Been there, done the statistics.

> I don't want different things looking the same.

That was the point: they are not different.  Polymorphic.

> It sucks.
> That's an opinion.  I prefer it that way.  That doesn't make it better.

Your opinion is noted.  The benefits of OO, however, are not opinion.

They are indeed quantifiable.

> Objects are *NOT* ipso facto the Answer.

I never said that they were.  They provide a step in the right
direction.

> Bad programmers persist.

Indeed.

John S.





More information about the Python-list mailing list