Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Perl VS Python

by thpfft (Chaplain)
on Aug 05, 2001 at 01:00 UTC ( #102271=note: print w/ replies, xml ) Need Help??


in reply to Perl VS Python

There are four ways in which one language might be better than another, off the top of my head. any remarks about python which follow are not very well-informed, by the way.

1. it suits your tasks
If you're munging masses of data, dealing with texts, creating conversational interfaces, doing things quickly, designing as you build (oops), or no doubt many other things I haven't encountered, perl is what you need. I'm afraid someone else will have to write the corresponding python list, but i'm sure it's long too.

2. it suits your temperament
Perl is muscular, idiomatic, expresssive, poetic, ambiguous, robust, a little messy. Python is meticulous, brittle, precise, clear and direct. There are people who prefer that, and it certainly makes it easier to read someone else's code. But less fun.

3. it's widely-used
This confers obvious benefits in terms of your employability and versatility. In the case of perl it also gives us cpan, which is priceless, perlmonks, *.pm, and so on. It's not a level playing field, of course: perl's ubiquity is an accident of timing as much as anything. If python or ruby had been a normal part of the unix toolkit when the web exploded, who knows what this site would be called?

4. it's powerful
This is really the same as (1) - it can't be taken out of context and still mean anything - except for the fact that your tasks might change, or your understanding of them. If we had to define power, it's probably a product of the range of uses to which a language can be put and its ease and strength in each case. In that context, perl is more powerful than python: it's more versatile, it's easy to grasp and in the hands of a good idiomatic programmer, very strong indeed. But there are well-understood edges to the domain in which perl excels, and C is more powerful still, on this scale. But if it doesn't suit your needs...

To me, perl is better suited to my work and my tastes than anything else out there, and in my opinion it's a better investment in terms of what it might one day allow me to do.

but ymmv

PS. one quite often encounters arguments based on what perl programs are like, rather than what perl is like. If you come across one, make sure that people are comparing like with like. There's a lot of bad perl out there, not because perl is bad but because it's accessible and forgiving. These are good qualities.


Comment on Re: Perl VS Python

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://102271]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (5)
As of 2014-08-20 23:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (125 votes), past polls