Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

Perl v. Python: Can't we all just get along?

posted by jjohn on 2000.04.10 15:44   Printer-friendly
Without the heat of some other sites, I'd love to read a discussion on why a Perl lifer should give Python a whirl. There seems to be much rivalry between these languages, and I for one would like to see more cross-talk and integration. What do you all think about this?
The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • I think Python has some things to teach us about language design, but mostly by negative example. (Whitespace-dependency: Bad. No equivalent of "use strict" or "my": Bad. Etc.)

    More significantly, I think, the (d)evolution of the Python community's vaunted politeness teaches us, again, that: The Center Cannot Hold; Things Fall Apart. Perl's community being as fractious as it is (as we are!) is evidently inevitable, simply because it has grown too big to remain tight-knit.

    I think it's worth noting th

  • I've never seen much point in the discussion "Perl or Python"? And unfortunally, most participants in the discussion know at least one of the languages not well enough to contribute something worthwhile. Many Pythoners don't come further than "too much punctuation", while many Perlers don't come further than "the mandatory white space". I don't know about others, but if all you can come up with against a language is "mandatory white space", I wouldn't program in any other language anymore.

    I don't have muc

  • Abigail writes:
    • Many people are much better of with a language that forces you to do things in a specific way, that has stricter rules on doing things. For those people, Python is much better.

    If this choice is based on personal preference, that's OK with me. But if this choice is based on a misguided notion of Python being somehow intrinsically better because of its being simpler, more regular, etc., then it is wrongheaded and sets a dangerous precedent. I think Stroustrup said it best:

    • Rule: "D
  • One of the reasons I posted this article is because I'm tired of the habitual Perl slander:

    1) No one can write maintainable Perl code
    2) Perl has (awful syntax|wonderful line noise)
    3) Perl is too much like (C|AWK|BASIC)
    4) Perl's OO is sloppy, therefore useless

    Now, if Python really was Fred Brooke's silver bullet to slay the software engineering beast, I'd be shouting the word from the roof-tops. Python is does not significantly reduce the complexity of software development. "Cleaner" or more restricti
  • I sympathize with your frustration over the 'habitual slanders'.

    Perhaps you could adopt a Python advocate. I've adopted one. I got him to agree that he would never write anything negative about Perl unless he fact-checked it with me first. So far, I haven't seen him write anything new that's negative about Perl.

  • One of the best reasons I can think of for a Perl lifer to learn Python is simply because it's Not Perl (tm). A good Perl programmer lives by TMTOWTDI, and Python is simply another WTDOI.

    Among the recommendations in The Pragmatic Programmer (extracts here) [pragmaticprogrammer.com] was "Learn a new programming language every year." (p14) I do not interpret this to mean start writing a C compiler in Scheme just because this is the year to learn Scheme; rather, examine new approaches to solve the same old problems. Over time, ex

  • OK, you got me. There's more to Python than the language, and learning it is worthwhile. There, I said it. Now if I can just overcome my distaste long enough to actually _do_ it....
  • I decided several weeks ago to give python a hard look and I have to admit, once I got over the whitespace has semantics thing, it really became an enjoyable language to program in. Why should a perler learn python? I don't know. Python seems to fill much the same programming niche as perl, just fill it differently. I decided to learn python because 1) Everybody was talking about it 2) lots of tools I wanted to look at and use are written in python (sgmltools, Zope, etc) and 3) just because I love to pr
  • Let me start off by saying that I don't usually read this site. I was pointed here by a python programmer who wanted more python people to join this dicussion. However I'm not exactly a "python person." I'm most comfortable in C, with a smattering of Java, Perl, Asm, Lisp and Python (in no particular order). That being clarified, I'd like to say a few words.

    First of all, I don't want to offend anyone, but Perl really is an example of the most horrible way to design a language. I say "design" with ton
  • The implementation itself [of perl] is rather unfortunete; because of how it's built you can't really implement perl in terms of itself

    I've always wondered why people place so much importance on this. How often does Joe Random User implement a compiler? I'd say that Perl helps solve a certain set of problems easily and that writing a compiler isn't one of them.

    ... the entire system needs to be scrutinized by security experts before any program written in Perl can be considered secure, and it is doubt

  • I don't think that python's semantic whitespace in and of itself is bad. It makes programs very readable and once you get used to it, you file away "Is the indentation proper?" in your list of things to look for when there are problems. Where semantic whitespace becomes burdensome is when error messages from the compiler are so cryptic as to be useless. Python's current error messages remind me of days long past when almost every error from a C compiler would simply be "syntax error" and you had to guess
  • Perl really is an example of the most horrible way to design a language. I say "design" with tongue-in-cheek, because the language wasn't really designed so much as thrown together from pieces of odd scripting languages (many of which should have been put to rest long ago).

    I disagree. Perl was certainly designed. However, it was designed by someone (Larry Wall) who was first of all not a typical computer scientist, but someone with a very strong background in linguistics, and second, he wasn't to pride t

  • Perl was designed as a language to help Unix system administrators scan through flat text files of arbitrary size, gather information from such files, and report on them. When it first appeared, it was conspicuously better for this kind of work than competing languages (awk, sed, C, and the various shell scripts); therefore it became very popular among Unix sysadmins. These early users had at least a passing familiarity with C and the Unix shell, so they wouldn't have considered Perl's syntax to be a barr
  • W.W.

    You claim that Perl is badly designed, but fail to give examples of where its faults lie. Perl was not "thrown together from ... odd scripting languages". It was certainly influenced by awk and sed. You are throwing FUD about the security hazards of Perl. Perl 5.004 was released without CERT advisories. Now, individual perl scripts may have problems, but don't blame Perl for that.

    You seemed to equate the ability for a language to implement its own compiler as the acid test for a 'real' language. The
  • Unfortunately, and "I don't mean to offend anyone," your statements betray a vast ignorance about Perl. That in itself is not a problem. My wife knows less about Perl than you do. But you speak as though you know what you are talking about, and therein lies the danger. I don't need to make specific points showing your igorance, others already have.

    Sigh. I really don't want this to turn into a place of flames, and I commend those who haven't engaged in flames. But I would be much happier if people di
  • People do get hung up on 'data hiding'. I often wonder how valuable this is for the compiler/interpreter to enforce. Isn't simply documenting the API enough?

    You want data, and more importantly implementation hiding because you do not want to publish those things in the API, and force yourself to never ever be able to change your implementation because someone using your stuff depends on it.

    Unfortunally, with Perls (and to a lesser extend with Pythons) OO, this is not possible. In Perl, you need to

  • Ah, Pudge! Flames are half the fun!

    In any event, I posted the article in good faith. I was hoping some Pythoners would rationally explain the benefits to the language, or what problems Python excels in solving. I still hope this comes out.

     
  • It was not your article I have a problem with, it is someone posting authoritatively that which is blatantly false, seemingly for the purpose of stirring up trouble.
  • Well, I think the semantic whitespace is bad in itself, because self-contained code structures no longer look self-contained.

    But I know some people aren't as hung up on graphical appearance of code as I am, so I don't make a huge point of it in most discussions.

  • As such, I've moderated the post down as flamebait.

    All articles have score 1 in this thread, although some are marked "interesting" or something else. Also, my User info page has conflicting information about the score of some articles.

    -- Abigail

  • I hope that flames will not become the norm here, because I'd rather stay than leave.
  • ...extremely disturbing, but I suppose it's only natural for people to abuse their power to further their own agendas. No, I really didn't mean to offend anyone, althought it's sometimes hard for me to tell because I don't get offended easily, especially not over a trivial thing like the strengths and weaknesses of a programming language. If you find yourself that upset because someone has said bad things about Perl, then you ought to examine yourself and what you consider important values.

    I don't think
  • OK, here's an exercise. Compare:

    • If we keep things civil and don't resort to slanderous methods, we can at least make the flaming dignified.

    And contrast:

    • I suppose it's only natural for people to abuse their power to further their own agendas.

    Here endeth the lesson.

  • Sigh. You wrote I don't think it's really fair for you to say "I don't need to make specific points showing your igorance", but that is not what I wrote. The entire sentence was I don't need to make specific points showing your igorance, others already have. While that comma should have been a semicolon, I think the point was still clear: others showed how your post was ignorant, so for me to do it would be redundant. But because I am a nice guy, I will be redundant on request.

    1. You say "Perl really
  • how come no [one] in this thread is defending python?

    Because python doesn't need defending. Nor does perl. This isn't a contest for supremacy on the grand totem pole of programming languages. Perl has merits. Python has merits. Perl has ickiness. Python has ickiness. I believe this thread started with "why would a perler use python?" To answer that, we have to highlight the good and bad in both languages. Because after all, TMTOWTDI, including not using Perl.

    As an aside, I notice that many of th