This sounds like a copy+paste from a textbook. Have you actually done any work with XSLT? Have you actually written dynamic webpages in PHP or written OO code in Python or Ruby? How much text processing have you done with awk/sed/etc?

Of all the things you mention, the one I have no experience with is Python. Of all the other claims, the only one I can confirm is that Ruby OO is cleaner. I strongly disagree on all other points.

XSLT is a gigantic pain to work with, for a large variety of reasons from the mundane to the esoteric. Given the choice and an XPath capable XML module, I'd use Perl over XSLT every time without fail.

For text processing… well I don't know how you can write what you did, because Perl was invented because these tools were too limited to begin with. Note that I'm not sure what yacc is doing in that list, because it has a very different focus than the other tools (they're all about processing text in the furthest possible sense, I guess). I've written tons of trivial and non-trivial sed scripts, and while my awk exposure has been limited, I have written a handful of non-trivial scripts, enough that I think I have a feel for the language. None of these tools is very useful for anything more than pretty simple tasks.

As far as PHP is concerned, it really should be likened to the Template Toolkit rather than the whole of Perl. Give me Perl, any day of the week.

Just about the only thing that I can think of where Perl is a bad choice is raw, unadulterated number crunching. PDL helps, but really that's the domain of C. For any kind of data munging task — not just pure text processing, but really anything that involves combining or extracting data somehow, whether that be XML, database work, or whatever you can dream of —, no competitor comes close to Perl.

Makeshifts last the longest.


In reply to Re^2: perl's forte by Aristotle
in thread perl's forte by kiat

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.