Slashdot Mirror


Perl Turns 25

Several readers sent word that the Perl programming language turned 25 today. In his commemorative post at the Perl Foundation's website, mdk wrote, "So what does the future hold for Perl? Well I don't have a crystal ball but I cannot see the language fading from usage in the next quarter century, the truth of the matter is that even though there are languages that can do some of the things that Perl does, some of them do some things better, others do things Perl wasn't designed for, there is no language that has been designed to do the things that Perl is very good at doing. No language in the current scripting languages seems to have the flexibility, maturity and extensibility of Perl. The main power of Perl has always been its ability to quickly adapt, and be adapted, to suit purposes. ... The greatest challenges we will face for Perl is a shifting end-user base that will become more reliant on devices that are feature focused but crippled in application choice, the rise in mobile devices will continue and Perl will need to evolve to work with that. A better challenge for us to face would be the integration with electronically aware, and connected devices and systems, the apocryphal internet of things, in this Perl could be a powerful tool. I also believe that the more we see a divergence of language uses in the other scripting languages the more they will face issues in their core designs, issues that Perl avoids due to its malleable nature, what some believe is the crippling factor for Perl is likely to be its saving grace as it has the power and flexibility to cope with the shifting goalposts of an increasingly technologically reliant world."

263 comments

  1. Recent convert by DCFusor · · Score: 5, Interesting

    I recently became a fan of perl as my goals changed towards things it excels at - sticking together big other functionalities easily.

    --
    Why guess when you can know? Measure!
    1. Re:Recent convert by vlm · · Score: 5, Insightful

      AKA I'm a CPAN programmer not a Perl programmer. Works for me! Wake me when another language has the depth of CPAN. I might switch, then. Maybe.

      --
      "Science flies us to the moon. Religion flies us into buildings." - Victor Stenger
    2. Re:Recent convert by DCFusor · · Score: 5, Interesting

      Yup. Me too. It's just awesome to be able to get stuff from CPAN with about the right "chunkiness" and documentation vs say trying to learn some huge monolithic library. Better yet - those cool modules often "accidnetally" document other things, like say, Gnuplot, so you can roll your own specialized versions easier than trying to understand the "native language" dox written by someone who didn't code in some other language, then translated by another non-programmer. And I can't believe I got first post.

      --
      Why guess when you can know? Measure!
    3. Re:Recent convert by Anonymous Coward · · Score: 0

      When you stick things together using perl, it's called...

      A Perl Necklace!

    4. Re:Recent convert by Anonymous Coward · · Score: 2, Informative

      there is, it is called "CPAN+Gems+PyPi+Maven" ... amazing stuff out there if you're agnostic. Rubyists, in particular, seem to write amazing tools. Chef and Vagrant are two of my faves.

      However, I still don't recommend you use Node.js.

    5. Re:Recent convert by Anonymous Coward · · Score: 3, Informative

      RubyGems is very expansive, but the quality of the modules that rubyists write is atrocious. The language is such a poor performer (spend 30% of the time doing GC, oh but don't worry better GC is in the next version, oh wait the next version, nm the next version), and the whole Rails community is built around absurd bloat: nobody seems to care/notice that their gems are poorly implemented for anything other than scraping something together.

    6. Re:Recent convert by thetoadwarrior · · Score: 2, Interesting

      It's a great language actually. Instead of people moaning that people write shit perl (like any other language), why no learn to do it right and enjoy it. CPAN of course is a tremendous resource but even on it's own it's not hard at all to write or understand and on the off chance you see something you don't understand, perldoc will almost certainly cover and well because that's another thing that Perl has (along with Python) that many languages lack and that is exceptional documentation.

    7. Re:Recent convert by thetoadwarrior · · Score: 1

      CPAN is great but it's not always wise to be too dependant on it for everything. Especially if you provide scripts to others to use and want minimal hassle.

    8. Re:Recent convert by thetoadwarrior · · Score: 2

      CPAN has some of the highest quality compared to other repos (especially compared to javascript), it has test stats for dependencies, quick access to view the source without downloading, documentation and just about any other info you want. Pypi is great for finding things and installing but supporting information is lacking. Maven I can't comment on but Ruby suffers from the same sort of problems that other brogrammer languages suffering from (more variety in quality and a lack of documentation).

    9. Re:Recent convert by Jane+Q.+Public · · Score: 1

      "RubyGems is very expansive, but the quality of the modules that rubyists write is atrocious."

      This is very definitely an over-generalization. Sure, there are a lot of crappy Gems (add-on code libraries) out there. But there are also a lot of them that are most excellently written and executed.

      I would say that Sturgeon's Law applies: 90% of it is crap. But 90% of everything is crap.

    10. Re:Recent convert by Anonymous Coward · · Score: 0

      I didn't like it 25 years ago, nor 10 years ago (too many security issues to list) and I still don't like it.

    11. Re:Recent convert by devent · · Score: 1

      Java. There are thousands open source libraries available on Maven Central Repository: http://mvnrepository.com/
      Containing the compiled library, the source code and the documentation.

      --
      http://www.mueller-public.de - My site http://www.anr-institute.com/ - Advanced Natural Research Institute
    12. Re:Recent convert by gottahavea · · Score: 2

      Yeah, me too. About 6 years ago (we can call that 'recent' from a Perl perspective can't we?).

      I'm a programmer that became a sysadmin. Perl is there, right down the pipe: shell based tools, connect to whatever DB you want, publish data via web applications, munge text data however you want ... This is the schtuff that I need, regularly. And wherever I'm moving CPAN is there. I can do it on *NIX, I can do it on *doze, just code up my little bits and get it done.

      Perl wins by the power of applicability. Yes, python can do many if not all of the above, and I recommend python for people learning to program. But I'm an old *NIX guy, and after a little study (required for any new language) it is 'hand in glove'.

      As for 'cats on keyboards' and other illegibility assertions: you can do that in any language. Write req specs, and design docs, even if brief, and remember that there are two programmers in every project: you and you in 12 months. Comments in code are like the units in data; contextual meaning.

      My heartfelt thanks to L Wall and the perl community, everywhere. Long may we be able to write what we want, where we want, how we want !!

      Happy birthday Perl :-D

    13. Re:Recent convert by Anonymous Coward · · Score: 0

      90% of it is crap. But 90% of everything is crap.

      Strikes me as the kind of excuse that keeps 90% of things as crap. (Also leaves a pitfall of poor components for small developers and startups to encounter.)

  2. If COBOL is still around ... by Kittenman · · Score: 1

    then Perl will be for a while too. Happy Birthday Perl. Your prime was memorable, and now you can just ask those kids to get off your lawn.

    --
    "The greatest lesson in life is to know that even fools are right sometimes" - Winston Churchill
    1. Re:If COBOL is still around ... by smittyoneeach · · Score: 1

      Hmmm. . .Visual Basic. . .PHP. . .

      --
      Get thee glass eyes, and, like a scurvy politician, seem to see things thou dost not.--King Lear
    2. Re:If COBOL is still around ... by thetoadwarrior · · Score: 1

      Unix is still very dependant on Perl. People can sit there and say no one uses it anymore but they don't realise how many things depend on it. Hell even popular OS X programs use perl which is why Apple's version of Perl can be out of date. In some instances language changes would break the scripts the particular version of OS X.

  3. Duct tape of the web by Anonymous Coward · · Score: 1

    Perl is few programmers' idea of an elegant language, but it gets the job done quickly and easily in situations where you'd otherwise be racking your brain and scrolling through endless Google hits to figure out how do it with sh, awk, and sed.

    When the WWW first exploded into the public consciousness, there was a very simple standard called CGI for returning dynamic content. Although CGI apps could be written in practically any programming language, the use of Perl was so dominant that newbies used to post questions like "Where can I learn about this Perl CGI language?"

    1. Re:Duct tape of the web by preaction · · Score: 1

      They still do that, because the web is timeless. The majority's view of Perl seems to be stuck back in the 90s.

    2. Re:Duct tape of the web by jellomizer · · Score: 1

      Part of Perl's success early on for CGI, was the fact that Open Source and Free Databases were hard to come by, and/or weren't so useful.
      The players in the Database Market were charging thousands of dollars for even the smallest usage.
      To replace the need of the Database we needed a language that was good for Text Parsing. Perl is good at that. However as time went on and tools such as MySQL and PostGreSQL, and Microsoft SQL Server (Not free, but lower cost than the others) started to come up and become more widely used, we see Perl became less popular and replaced with PHP and ASP(.NET).

      --
      If something is so important that you feel the need to post it on the internet... It probably isn't that important.
    3. Re:Duct tape of the web by jandrese · · Score: 1

      Really, PHP is a slightly warmed over version of Perl anyway. What's a much bigger impact on Perl's web marketshare is stuff like Ruby on Rails, which try to automate nearly everything for the developer.

      --

      I read the internet for the articles.
    4. Re:Duct tape of the web by FacePlant · · Score: 2

      > The majority's view of Perl seems to be stuck back in the 90s.

      The majority generally do not pay attention, and also hate it when their view of the universe is threatened by facts.

      Perl will continue to have it's place, as do Fortran, COBOL, etc. It wasn't my first language, and isn't my last, but it's still my bread and butter.
      Despite using it for 20 years, there are still some things that are idiomatic AWK for me. I'm sure it will be the same way with Perl, even after I've used Ruby or Python for a long time.

      --
      My Heart Is A Flower
    5. Re:Duct tape of the web by Brian+Feldman · · Score: 1

      Excuse me, what? How does a web application framework like Ruby on Rails try to automate nearly everything for the developer? Are you basing your opinion on it on trade materials?

      --
      Brian Fundakowski Feldman
    6. Re:Duct tape of the web by approachingZero+ · · Score: 1

      'The majority generally do not pay attention, and also hate it when their view of the universe is threatened by facts.' That is so good I'm going to steal it.

      --
      'I don't know what it's called. I just know the sound it makes, when it takes a man's life.' ~ Four Leaf Tayback
    7. Re:Duct tape of the web by Anonymous Coward · · Score: 0
      "Perl will continue to have it's place"

      So will the apostrophe, but that wasn't it. What blows my mind are people who can happily make sense of Perl but are utterly baffled by the apostrophe.

    8. Re:Duct tape of the web by multicoregeneral · · Score: 1

      What color is the sky on your planet? I wish people would stop saying ignorant shit like this. None of that is true. PHP (or people hate perl) has never been Perl, and works differently than Perl. Similarities between the two are superficial at best. I would argue that Rails isn't really even Ruby, let alone Perl, which isn't Ruby either.

      --
      This signature intentionally left blank.
  4. Perl Turns 25... by Frosty+Piss · · Score: 5, Insightful

    ...And is sexier than ever.

    --
    If you want news from today, you have to come back tomorrow.
    1. Re:Perl Turns 25... by Anonymous Coward · · Score: 1

      Especially with a perl necklace.

    2. Re:Perl Turns 25... by Anonymous Coward · · Score: 0

      Especially with a perl necklace.

      Disgusting pervert...

    3. Re:Perl Turns 25... by Anonymous Coward · · Score: 1

      Perlvert...

    4. Re:Perl Turns 25... by lipanitech · · Score: 0

      A lot of websites are still written in perl. Facebooks original layout was all perl I think they might still even use some in there programming. If I am not mistaken I be leave Amazon and eBay use some in there layout as well.

  5. I used it. Once. by Tsingi · · Score: 5, Interesting

    I wrote an app in Perl once. It was the only language that I could get to reliably connect to MSSQL from Linux.

    It was fun to write, but I go back and look at the code now and it looks like Greek.

    On the upside it's been running for over 5 years and having no problems at all.

  6. Perl where are you tonight by Wansu · · Score: 3, Funny

    Perl where are you tonight
    how can I now run scripts on my own
    I searched the filesystem
    even looked in slash sbin
    They rm'd the sym link and pffft you wuz gone

    --
    Wansu, th' chinese sailor
    1. Re:Perl where are you tonight by Anonymous Coward · · Score: 0

      I wonder how many people know the melody that goes with this?

    2. Re:Perl where are you tonight by Trailer+Trash · · Score: 2

      In case you need the tune:

      http://www.youtube.com/watch?v=EpNJuS3b0So

  7. What's with the camel? by Anonymous Coward · · Score: 0

    Please educate me on the camel icon for perl. I do not understand?

    1. Re:What's with the camel? by smittyoneeach · · Score: 2
      --
      Get thee glass eyes, and, like a scurvy politician, seem to see things thou dost not.--King Lear
    2. Re:What's with the camel? by preaction · · Score: 1

      O'Reilly needed something for the cover of the book (Programming Perl, now widely known as The Camel Book).

    3. Re:What's with the camel? by larry+bagina · · Score: 2

      a camel is horse designed by committee.

      --
      Do you even lift?

      These aren't the 'roids you're looking for.

    4. Re:What's with the camel? by fredrated · · Score: 1

      And a camel does a damned fine job in it's environment, where a horse wouldn't survive. Way to go, committee design!

    5. Re:What's with the camel? by lennier · · Score: 2

      a camel is horse designed by committee.

      A committee of hard-core desert survivalists who wanted an animal made of pure awesome.

      --
      You are not a brain: http://books.google.com/books?id=2oV61CeDx-YC
    6. Re:What's with the camel? by geekoid · · Score: 1

      Once again proving a bureaucracy does complex things well. That's why they were invented.

      --
      The Kruger Dunning explains most post on /. http://en.wikipedia.org/wiki/Dunning%E2%80%93Kruger_effect
    7. Re:What's with the camel? by Anonymous Coward · · Score: 0

      I do not understand?

      Are you asking us if you understand or not? Or was that meant to be a statement indicating that you do not understand? Question marks are for questions. Statements about your lack of understanding are statements, not questions.

    8. Re:What's with the camel? by Anonymous Coward · · Score: 0
      "And a camel does a damned fine job in it's environment"

      And so does the apostrophe, but that isn't it. What completely baffles me are people who can understand Perl but are rendered helpless by the apostrophe.

      Like, "it's means it is? WAAAAHHH TOO HARD!! But "#$^$#~~~!*&*(&^~~~" is obvious!

  8. REXX! by BeemerBoy · · Score: 1

    FTW!

    --
    Buzzing the information Superhighway at Warp speed
    1. Re:REXX! by gmuslera · · Score: 1

      Was pretty used with Rexx when had to start messing with perl, almost 20 years ago. Urgh, it was so ugly, at least compared with the (for me at that time) elegant rexx way to i.e. parse strings. But also noticed how powerful perl was, how much more i could do with it, and eventually moved to it as my main scripting language when moved to Linux. Now moving between it, python and bash, depending on the problem, even if i could do most with just one of them. But probably would not be using back Rexx, not sure how much the language changed, but I did.

    2. Re:REXX! by jandrese · · Score: 1

      I was a big REXX user back in 1995 and 1996, when I was stuck on PC-DOS and Windows 3.10 (couldn't afford Win95 being a broke student at the time). REXX was about a billion times better than the .bat files I would otherwise use (even with the fancy .com files you could use to make the .bat more functional). However, once I installed FreeBSD 2.1 and learned Z-Shell and Perl4 it instantly became obsolete.

      --

      I read the internet for the articles.
    3. Re:REXX! by dbIII · · Score: 1

      No no - forget it - Rexx is just one big bug.
      Oh wait - that's Lexx!

  9. Web Server development by Runesabre · · Score: 3, Insightful

    I remember when Perl was the workhouse behind all custom web server development. One of the few times I had "fun" writing code. Such a cryptic looking language that made perfect sense the moments you are writing it and completely alien days later.

    --
    Runesabre
    Enspira Online
    1. Re:Web Server development by Frequency+Domain · · Score: 3, Funny

      It always struck me as one of the poster children of "write-only" languages, right up there with APL.

    2. Re:Web Server development by Anonymous Coward · · Score: 5, Insightful

      Perl is write-only in the hands of stupid hacks. Oh wait, that's any language.

    3. Re:Web Server development by Anonymous Coward · · Score: 1

      More like any language but Perl, where even experts are confused by their own code seconds after writing it.

    4. Re:Web Server development by Maximum+Prophet · · Score: 1

      That's the case with most object oriented languages these days. OO Perl is the worse. It's not just the language, it's the culture.

      Instead of a simple A() calls B() and C() to do work, where B() and C() do real work, I've seen code where B() and C() are almost empty, relying on strange language contructs known only to true believers and their IDEs.

      --
      All ideas^H^H^H^H^Hprocesses in this post are Patent Pending. (as well as the process of patenting all postings)
    5. Re:Web Server development by Frequency+Domain · · Score: 5, Funny

      A friend was editing a perl program when his cat walked across the keyboard. It took him a while to figure out which parts were written by the cat. That's when I decided to avoid perl.

    6. Re:Web Server development by dotgain · · Score: 5, Insightful

      Your friend should look into revision control software and possibly getting the cat his own terminal. This way the cat's contributions can be easily tracked.

    7. Re:Web Server development by geminidomino · · Score: 1

      relying on strange language contructs known only to true believers and their IDEs.

      Heathen. True Believers in perl don't use IDEs, regex generators, auto-intent, or syntax highlighters, and we don't receive our golden "@" medallions until we can determine the output of feeding our code through "perl -wt" in our heads.

       

    8. Re:Web Server development by Kymermosst · · Score: 1

      Bad coders can write bad code in any language.

      There is nothing that requires that Perl code be write-only.

      --
      "Alcohol, Tobacco, Firearms, and Explosives" should be a convenience store, not a government agency.
    9. Re:Web Server development by gorzek · · Score: 2

      You guys should be glad you don't write MUMPS code.

    10. Re:Web Server development by skids · · Score: 1

      I think you're right on most of that but syntax highlighters. We use them because we like to try to break and improve them, since we know it's almost impossible to get them 100% right, given pragmas and whatnot.

    11. Re:Web Server development by Anonymous Coward · · Score: 0

      Write-only is way cool, no? Totally obviates the need for source control. Not having to worry about changes --- kind of like functional programming taken to a higher level.

    12. Re:Web Server development by Celarent+Darii · · Score: 1

      APL is write-only because you need a special keyboard to write APL. What a pain trying to correct a bug from a terminal without those characters! Perl at least sticks to ASCII characters, so you can debug and write perl from almost anywhere. Yet there is something about the information density of APL that is attractive - it is a piece of art, so like a sculptor you sort of chisel away at it. Perl is more of a painters language.

    13. Re:Web Server development by Coryoth · · Score: 2

      There is nothing that requires that Perl code be write-only.

      No, there isn't ... but there's nothing that encourages it either. And perl has a elatively high congitive load in terms of all the many subtle features and idioms that you need to keep track of. If you're reading code that only uses a subset of idioms and features that you're comfortable with it's fine, but it is relatively easy to end up outside your comfort zone with other people's code unless you are deeply invested in the language. In this way it is much like C++.

      In practice however a lot of Perl's reputation for unreadability is historical, and cultural. Back when Perl was more popular there was very much a culture of "neat hacks", JAPHs and perl golf. That meant that a lot of Perl code you saw in examples was often cryptic, or revelled in terse complexity.

      These days I think Haskell has taken the crown for the culture that produces terse, complex and cryptic code. There's nothing in Haskell that means it has to be hard to read, but a culture of showing off with terseness has developed and ...

    14. Re:Web Server development by randomac · · Score: 1

      Having a lot of experience with APL, my first encounters with Perl led me to the realization that Perl is truly 'write-only': Type in an expression: var = expression -- sure there's supposed to be some profanity at the start of the name $ or % or @ or something, but bear with me.... try to get the result out var {something that effectively says: I'm not telling, like {aList} or some such.... not impressed. ) at least with APL you can see data values. One good thing about Perl: it is not a pin-head language, one where functions can only return scalar results.

    15. Re:Web Server development by randomac · · Score: 1

      Debugging APL on old DOS machines, without the codepage magic, not that difficult. One quickly got used to 'gamma' being 'iota', 'square root' being 'rho', 'o acute' being 'quad'. Unicode removes all that, and APL got its own place in Unicode as well.

    16. Re:Web Server development by david_thornley · · Score: 1

      I'm not exactly an expert, which may be why anybody else who kinda knows Perl can figure out what I've written. Seriously, I don't play code golf (minimizing characters to write a program), and if I did I wouldn't put it into production.

      --
      "When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
    17. Re:Web Server development by Anonymous Coward · · Score: 0

      Hey get me the name of that cat! Always looking for someone to review my code and how cool is a Perl coding cat!

    18. Re:Web Server development by Celarent+Darii · · Score: 1

      Maybe not that difficult, but painful nonetheless. Like transcribing from one key to another in music and still trying to play live. It can be done, but really not my cup of tea. To bad slashdot doesn't do unicode, or I would give some examples. In any case, hats off to you if you can debug APL without difficulty !

  10. Why perl? by Frequency+Domain · · Score: 4, Interesting

    What can perl do that newer languages such as python and ruby can't do, and do more readably/maintainably?

    I understand about path dependence and sunk costs, which is why we still have COBOL, I'm asking about language features that are unique to perl.

    1. Re:Why perl? by Anonymous Coward · · Score: 1

      The original use of Perl was as "awk on steroids" which I think was Larry Wall's phrase. Perl features an active model where the while loop pulls 0-terminated records from standard input, or any other file, whereas awk has the passive filter model. Once you get get past the loss of elegance, you realize that the active model gives you the full power of a high level scripting language seamlessly combined with all of the regex facility of awk.

      And Perl kept growing.

    2. Re:Why perl? by miletus · · Score: 5, Interesting

      How much of readability is the fault of the language vs the developer? Cut-n-paste coding is the bane of any language.

      As a perl programmer, I sometimes ask, what can python or ruby do that perl can't?

      MVC web framework like Rails or Django? Catalyst, Mojolicious, etc. PSGI has taken a lot of pain out of deployment of apps.

      Good, modern object system? Moose.

      GUI stuff? There's Wx and Qt interfaces.

      OK, embedding C looks much easier in python, but I've never needed that.

      If all the CPAN stuff would just work with other languages, I'd be more willing to switch. Javascript seems to be where all the web stuff is heading anyway.

    3. Re:Why perl? by Trepidity · · Score: 1

      For script-type usages, where I might otherwise have used bash/awk or something, Perl feels like it retains more of the lightweight, quick-to-script aspect. I like autovivification, the implicit $_ variable, etc. They can be used to make unreadable code, but in idiomatic usage they're very nice and not particularly hard to understand.

      I don't really use Perl for "big" applications, though. Mostly for text processing and "glue" between other tools.

    4. Re:Why perl? by smittyoneeach · · Score: 1

      Mostly perl's emphasis on sports: http://c2.com/cgi/wiki?PerlGolf

      --
      Get thee glass eyes, and, like a scurvy politician, seem to see things thou dost not.--King Lear
    5. Re:Why perl? by Maximum+Prophet · · Score: 2

      Mostly inertia and a great set of libraries in CPAN.

      There's even a Perl library that will hold your C code, compile it when needed, and make it easy to use.

      Perl just plain works and plays well with others. Compare and contrast that with Java or Smalltalk.

      --
      All ideas^H^H^H^H^Hprocesses in this post are Patent Pending. (as well as the process of patenting all postings)
    6. Re:Why perl? by Anonymous Coward · · Score: 0

      If PERL was a decent language, there would have been no need to develop alternative scripting languages. The fact that one programmer cannot read something written by another when they're both prefoessionals in the same language is pretty damning, only PERL has that claim to fame in over 40 years of languages.

    7. Re:Why perl? by preaction · · Score: 3, Interesting

      Surprisingly, embedding C++ in Perl is easier than embedding C. Of course, that's just my opinion, there aren't a lot of docs on the C++ topic, and I am one of the few Perl programmers who actually enjoy C++.

      The Parrot VM http://www.parrot.org/ is supposed to be for dynamic languages what the CLR and JVM are for Microsoft and Java respectively. If it ever makes it to prime time, then you could use your CPAN module with Ruby, or vice-versa.

    8. Re:Why perl? by Anonymous Coward · · Score: 0

      "What can perl do that newer languages such as python and ruby can't do, and do more readably/maintainably?"

      For one thing, I really hate the fussiness with whitespace indentation in python. At least with perl I can arrange things the way I like. That's not to say I'm sloppy about it. My code is very consistently structured. It's that python forces me to deal with it its way, and the rules are a lot less flexible. That *one* thing drives me up the wall so much that I'll stick with perl, thanks. This is not a unique feature of perl, however. It's python that is a bit odd in that regard.

    9. Re:Why perl? by Anonymous Coward · · Score: 1

      lol. PSGI being... a re-implementation of PEP 333 (WSGI for you non-Python people)?

      while I will not insult the language's capabilities, or the devotion of its user base, the fact is that the language's syntax bears the abuse of 25 years of "add whatever whenever" feature-itis. sure, an experienced developer might write readable code -- it might be concise, the hairy parts might be commented/documented -- but most Perl "developers" are scripters, not programmers, and they frequently produce fugliness that then lingers until someone like me has to be hired to untangle their mess.

      that being said, Perl does run the world. the obligatory xkcd applies -- as a real-life example, look to the standard Haskell compiler, GHC: an unholy mix of a Haskell language front-end, a GCC compiler port, and a final Perl script (aka "the Evil Mangler") to transform intermediate GCC output and implement features that GCC had not yet gotten around to -- TCO (tail-call optimization) and other niceties C users hadn't gotten around to clamoring for yet.

      tl;dr -- happy birthday you ugly bastard!

    10. Re:Why perl? by Hatta · · Score: 1

      If all the CPAN stuff would just work with other languages

      Couldn't it? Would it be possible, at least in theory, to compile CPAN modules to a binary format that could be linked to other programming languages? Is there any reason that CPAN couldn't be turned into something more like a shared library?

      --
      Give me Classic Slashdot or give me death!
    11. Re:Why perl? by Anonymous Coward · · Score: 0

      oh, and as the other jackass anon, "embedding C" in Python (actually the other way around, obviously) is much, much, much easier than nearly any other language. mostly because it was designed for that. I've heard tell of people using the Python runtime as the main loop for their not-at-all-Python-related program because it's basically a free reference-counting GC with a few other (very) nice features.

    12. Re:Why perl? by Anonymous Coward · · Score: 2, Informative

      How much of readability is the fault of the language vs the developer?

      When the language's answer to new features is to add a new operator instead of a library/function call, it's the fault of the the language. That Perl now has nearly 300 operators, that is a language smell.

      OK, embedding C looks much easier in python, but I've never needed that.

      Understatement of a lifetime. I've had to expose C++ apis to Perl, Python, Java & C#. Hands down the worst, by several orders of magnitude, was Perl. XS should be held in front of the world for judgement as the worst abomination and abuse of the C preprocessor known to development kind. That XS is held to be the best means of expose C to Perl is an even greater condemnation. By contrast, Python's C API is clear, well documented, and for the most part, any preprocessor macros involved behave and look like well-defined functions. JNI, I've only used it a little bit, so I won't pass much judgement, but the API was fairly clear and easy to understand. C#, the same way. C# has the added bonus that if you're interfacing with a pure C DLL, you can do it with DLLImport attributes. The gotcha there is just making sure you get the function signatures and marshalling correct.

    13. Re:Why perl? by Anonymous Coward · · Score: 0

      no. there is a panel of (top-flight professional) judges that spend weeks just attempting to judge what entries *do*; those they can't understand win.

      the language? C.
      the contest? IOCCC -- the International Obfuscated C Code Competition!

      never underestimate the complexity of a language, any language, with mutable state and impure functions.

      EDIT: perfect CAPTCHA -- "perverts"

    14. Re:Why perl? by jimbo · · Score: 1

      As a Software Developer I ask what language is appropriate for the project. It'll typically be the language the organization has standardized on already because you don't want to muddle up things.

      So I don't care much about language choice beyond that. Although I often approach existing Perl source with a certain tense anticipation, based on experience.

    15. Re:Why perl? by jgrahn · · Score: 1

      What can perl do that newer languages such as python and ruby can't do, and do more readably/maintainably?

      Don't know Ruby, but Perl is distinctly better than Python for writing text filters with regexes and stuff -- the things you used to use sed and awk for. More readable code, faster execution.

      (On the other hand, some people still stick with awk.)

    16. Re:Why perl? by dotgain · · Score: 3, Informative

      It's worth noting that Larry Wall won the IOCCC - twice. (I don't say this to support the GP's remark, more to attest to Larry Wall's awesomeness)

    17. Re:Why perl? by Anonymous Coward · · Score: 0

      Any comparable Perl option to Python's numpy?

    18. Re:Why perl? by Thud457 · · Score: 3, Funny

      Larry Wall won the IOCCC - twice.

      That just makes him incomprehensible in two languages.

      --

      the preceding comment is my own and in no way reflects the opinion of the Joint Chiefs of Staff

    19. Re:Why perl? by narcc · · Score: 4, Informative

      No one cares about ruby. It's a dying little niche language. It had a good run, but that's all in the past now. To me, ruby never really felt complete. (It didn't even get a step method to its range class until 1.8.7) There was always some absurd limitation you had to work around or some needlessly obscure feature or rule to learn before you can do something obvious in just about every other language (What's up with things like this? 10.times { |i| puts i } madness!)

      Python, well, python enjoys some popularity, but I just don't think it's likely to hang-on like perl. Probably because of the whitespace issue and the big 2.x 3.x split. Perl filled a particular niche really well, and was a good fill-in in a few others (remember when it powered your website's counter and guestbook?). Python never really found a home as there isn't any particular area where it really stands out -- or is even arguably a good fit. You'll find a lot of "it can be used for ..." but not a lot of "It's really great for ..."

      As for readability, well, I can't say that it's a terribly readable language. I get that everyone is forced to indent their code (apparently, the whole world forgot about pretty printers) but that's not all there is to readability. Neither is readability all there is to maintainability. (You could even argue that the whitespace rules actually hurt readability, as it takes away otherwise helpful cues.)

      Let's not forget that you don't have to write illegible perl code. Really, it's not required!

      COBOL's staying power was due to much more than "sunk costs". It was, and still remains, the best tool for the job. You'll find tons of failed COBOL to Java conversion projects from the late 1990's as a testament to that. It's really hard to beat COBOL on performance and even harder to find a language that's as easy to read and maintain. (Not that there isn't lots of room for improvement. It was designed to be readable, however, and it shows.) In short: It's easy to learn, easy to read and maintain, and lightning fast.

      Anyhow, to answer your question: Manipulating strings is a strength that is not shared by many other languages to any significant degree, and this makes it a great fit for a broad range of applications to which python and ruby just aren't as well suited. (Working with strings in python 2.x is terrible -- even just outputting them can be troublesome due to the bizarre default behavior of 'print'. This has improved, but not much, in 3.x) I would argue that PHP is popular due in no small part to that as well (I've always thought of it as a simpler version of perl. A related note: PHP was originally written in perl.)

    20. Re:Why perl? by bitslinger_42 · · Score: 1

      Having written in perl for the past 20 years, I started out trying to find something that perl can do that ruby can't (ruby is the only comparable language I have in my toolbelt). After a few minutes, I decided that, for the work that I do, the single feature that perl has that ruby doesn't is that I'm very familiar with how to write perl.

      I've liked some of the things that I was able to do with Ruby on Rails, and could see how having a MVC framework in perl would be useful, but quite frankly, most of the coding I do these days is emergency, one-off parsing jobs that need to be written yesterday. Under those circumstances, I reach for the tool that I know best, I'm sure I could probably become equally familiar with ruby, but since I've already got one tool that does the job, why?

    21. Re:Why perl? by bill_mcgonigle · · Score: 3, Informative

      Couldn't it? Would it be possible, at least in theory, to compile CPAN modules to a binary format that could be linked to other programming languages? Is there any reason that CPAN couldn't be turned into something more like a shared library?

      Yes, this is part of the perl6 effort. There are ports of all the other scripting languages to the ParrotVM being written for perl6. Once that's worked out you can write a module in Ruby, run it from Python - it doesn't matter. Use the best tool for the job (which is often the one you're most comfortable with).

      --
      My God, it's Full of Source!
      OUTSIDE_IP=$(dig +short my.ip @outsideip.net)
    22. Re:Why perl? by gorzek · · Score: 2

      I used to use perl as my "glue" language, too, until I got into python. Python works just as well in most cases, and usually leaves you with much more readable code. People who haven't used python before can usually figure out what some code is doing just by reading it. With perl? Good luck.

    23. Re:Why perl? by gorzek · · Score: 2

      People are still harping about this? Get over it. Python doesn't care how you do your indentation, as long as you do it in a consistent way. You also aren't wasting lines putting curly braces on everything. And you barely even have to worry about it if you're using any kind of python-supporting code editor for it. I'm not even talking about a full IDE. Even IDLE alone will do the job.

    24. Re:Why perl? by Trepidity · · Score: 1

      I've used Python for some things, but somehow it just seems clunkier to me. For example, if you want to scan a text-file line-by-line and run some regexes on each line, it's much more explicit in Python: have to explicitly read each line into a variable, hoist some re.compile()s out of the loop if you don't want them being recompiled on each iteration, etc.

    25. Re:Why perl? by gorzek · · Score: 1

      I've not found python's mechanism for using regexes to be any less powerful than perl's. It is inherently object-oriented, so it works rather differently. I've used both facilities and have never been unable to do what I wanted in either language.

      Also note that perl is only faster with regexes if they are static (that is, known at compilation time.) Python does them faster if they aren't known until runtime.

    26. Re:Why perl? by CaptSlaq · · Score: 2

      Larry Wall won the IOCCC - twice.

      That just makes him incomprehensible in two languages.

      Three, if you include English. If only I could be that incomprehensible...

    27. Re:Why perl? by DaveAtFraud · · Score: 1

      If PERL was a decent language, there would have been no need to develop alternative scripting languages. The fact that one programmer cannot read something written by another when they're both prefoessionals in the same language is pretty damning, only PERL has that claim to fame in over 40 years of languages.

      perl is a decent language. The problem isn't the language; it's the programmers. My bet is that it's possible to write unreadable code in any programming language (except maybe COBOL but then you just write enough of it that it bores anyone to death who tries to read it). As an example, take a look at something like what comes out of the Obfuscated C Contest. But I don't hear anyone saying we should junk C because it's possible to write C code that is almost completely impossible to understand.

      perl gets a nasty reputation for being unreadable because:

      1) People who have never used get told that the way to do what they want to get done is to do it in perl instead of doing it in bash, awk, grep, sed, etc. They have no idea how to use perl but muddle their way through to something that works but which should be burried.

      2) The opposite extreme are the perl experts who seem to delight in using obscure perl features in obscure ways rather than write something that a mere human can understand. I had one of these complain that my perl wasn't "perlish" enough.

      3) "Dave the web server is down!!! Can you write a quick perl script to fix the data coming out of the database so it doesn't crash the application? It's costing us $$$$ in lost revenue while the server is down."

      4) Take the perl that results from any of the above and then maintain it in production for a few years.

      Cheers,
      Dave

      --
      They that can give up essential liberty to obtain a little temporary safety deserve neither safety nor liberty.
      Ben
    28. Re:Why perl? by gorzek · · Score: 1

      Although it depends on what your memory restrictions are, if you know the file you're reading isn't enormous (that is, bigger than the memory you can spare), it's easier to just yank the whole thing into an array off the bat:

      lines = open('somefile.txt','r').readlines()
      # set up your regex and compile it here
      for l in lines:
              # do your re.search or whatever

      You only have to compile once if you aren't changing the regular expression from line to line.

      I agree that it's more explicit, but I don't see how that makes it "clunky." Rather, it makes it quite clear what you are doing with each line/command.

    29. Re:Why perl? by narcc · · Score: 2

      but most Perl "developers" are scripters, not programmers

      This is, quite possibly, the stupidest thing I've ever read -- and I've been known to read the comments section on World Net Daily articles.

    30. Re:Why perl? by Anonymous Coward · · Score: 0

      "People are still harping about this? Get over it."

      I've tried. But someone asked why I stick with perl, and this is one of the reasons: it allows me do more things my way. I know python has significant flexibility, but it's not as much as I'm used to or the level that I prefer. I know that code formatting might be a rather lame reason to not prefer a language. Sorry. And worse than that: I like braces! Ridicule me if you like, but the mere existence of so many web pages about python that explain why indentation and whitespace isn't a problem suggests to me that, actually, it is one of the obstacles to its more widespread adoption. Otherwise there wouldn't be so much discussion why people should "get over it".

    31. Re:Why perl? by RedHat+Rocky · · Score: 1

      Similar here, I decided to pick up Ruby because it is very perl-like. However, number of perl opportunities is low compared to Ruby-on-Rails.

      --
      Anything is possible given time and money.
    32. Re:Why perl? by Anonymous Coward · · Score: 0

      As a perl programmer, I sometimes ask, what can python or ruby do that perl can't?

      MVC web framework like Rails or Django? Catalyst, Mojolicious, etc. PSGI has taken a lot of pain out of deployment of apps.

      There's something deeply ironic about citing projects that willingly admit they're based off efforts IN the languages you're trying to state aren't needed.

    33. Re:Why perl? by RedHat+Rocky · · Score: 1

      One of the reasons I don't like Python:

      As long as there is enough memory....until there isn't. Oops.

      --
      Anything is possible given time and money.
    34. Re:Why perl? by mcgrew · · Score: 1

      What can perl do that newer languages such as python and ruby can't do?

      Have a Texan beer named after it?

    35. Re:Why perl? by skids · · Score: 1

      If PERL was a decent language, there would have been no need to develop alternative scripting languages.

      This made me laugh. Because it's patently obvious that, while necessity may be the mother of invention, she was not even in the same country when many programming languages were conceived.

    36. Re:Why perl? by skids · · Score: 1

      That Perl now has nearly 300 operators, that is a language smell.

      We'll have to agree to disagree there. It may take a while to learn them, especially their precedence, but once you do, leveraging that precedence gives you a lot more power and expressivity than functions.

      Which is why Perl6 is making it a one-liner to locally define new operators within a lexical scope.

    37. Re:Why perl? by Anonymous Coward · · Score: 0

      You can also mmap the entire file, and then use regular expressions compiled with the re.MULTILINE flag on the mmap. Then you don't have to read line by line, save a for loop and are happier.

    38. Re:Why perl? by thetoadwarrior · · Score: 1

      Why use scripting languages when you can write websites in C++? Just because you can do it in other languages doesn't mean you have to use them or Perl. But biggest reason imo for using Perl or Python is that they work much better across Unix systems. Everyone assumes your scripts will be perl or python. So you can write your website and supporting scripts all in one language and tie them together well with the website. If your site is kind of basic maybe that doesn't matter but sometimes you want code that can be fired off from multiple sources including the web. You can do that with any scripting language but the only two languages you can guarantee will be on a system are perl and python and writing CLI scripts in PHP is just stupid.

    39. Re:Why perl? by Anonymous Coward · · Score: 0

      What can perl do that newer languages such as python can't do

      Maintain backwards compatibility. You'd think it'd be easy, but Python can't seem to manage it......

      Why would you write code in any language if you knew you'd just have to rewrite it again later?

    40. Re:Why perl? by VortexCortex · · Score: 2

      Larry Wall won the IOCCC - twice.

      That just makes him incomprehensible in two languages.

      Three, if you include English. If only I could be that incomprehensible...

      You've got a good start. You don't "include" English; You: use English; in Perl.

    41. Re:Why perl? by stderr_dk · · Score: 1

      What can perl do that newer languages such as python and ruby can't do, and do more readably/maintainably?

      use common::sense;

      --
      alias sudo="echo make it yourself #" ; # https://pipedot.org/~stderr & http://soylentnews.org/~stderr
    42. Re:Why perl? by Jane+Q.+Public · · Score: 1

      "Good, modern object system? Moose. "

      Fine. But Moose is not Perl. It's an add-on. Ruby is designed from the ground up to be OO.

      "GUI stuff? There's Wx and Qt interfaces."

      Which apply equally to Ruby. And for Ruby there are also Shoes, MacRuby, and many others.

      "OK, embedding C looks much easier in python, but I've never needed that. "

      And Ruby supports it natively as well.

      "Javascript seems to be where all the web stuff is heading anyway. "

      Nonsense. JavaScript is a cobbled-together language with atrocious syntax and terrible, overly-verbose OO support. Sure, browser makers have expended a lot of energy making JavaScript fast. But if the same amount of effort had been devoted to Ruby and Python, they'd be fast now, too.

    43. Re:Why perl? by Jane+Q.+Public · · Score: 1

      "No one cares about ruby. It's a dying little niche language."

      Hahahaha! That's the funniest thing I have read all day.

      According to ">the TIOBE Index, Ruby moved up on the list again this month.

      When compared to 2007, yes, Ruby did move down one spot on the list, from 9 to 10. But that's largely because Objective-C came out of nowhere and is now at the top of the A list. During the same period, Perl moved down 2 points, PHP moved down 2 points, Visual Basic moved down 4 points, etc.

      Other similar sites show similar results. Statistically, what you say is just nonsense.

      There has also just recently started a movement to establish Ruby as a more frequently used language in the sciences, because it lends itself to such applications quite well, and has among the richest set of code libraries (Gems, in Ruby) out there.

      "(It didn't even get a step method to its range class until 1.8.7)"

      Completely untrue. Here is documentation of someone complaining about a potential regression error in step for ranges when Ruby went to version 1.8.6. So obviously it existed even before then.

    44. Re:Why perl? by Jane+Q.+Public · · Score: 1

      Correction. There was a typographical error in that first link. It should have been:

      The TIOBE Index

    45. Re:Why perl? by Jane+Q.+Public · · Score: 1

      "People are still harping about this? Get over it."

      Yes, people are still harping about this, and they aren't likely to stop.

      Making whitespace significant in a language is something that some people like and some do not. I am one of those who do not. And you aren't going to change my mind by saying that it's no big deal if you just use the right editor. (BTW... WHY should I have to use a special editor just for Python?) I have other objections to the practice as well.

    46. Re:Why perl? by hermitdev · · Score: 1

      I'll absolutely disagree with this. It's generally considered bad form to overload operators in any language unless the operators provide the exact same semantics as built-in types. I didn't even know Perl 6 allowed user-defined operators - now I hate the language even more. That, even with the built-ins, at the period table of perl operators, that there's even a class titled "ambiguous" ought to be a sign they've gone too far.

      This is why I refuse to, and never will submit myself to Perl development or maintenance.

    47. Re:Why perl? by mattack2 · · Score: 1

      People are still harping about this? Get over it. Python doesn't care how you do your indentation, as long as you do it in a consistent way. You also aren't wasting lines putting curly braces on everything.

      But you are wasting time/characters putting colons in various weird places.

      I actually LIKE Python, despite hating indentation == scope. If there's a way I could "turn it off" in a way that I could import into any script (i.e. not require a specific hacked Python interpreter), I'd like it even more. I don't care if it's {} or even BEGIN/END, while I want scope for *human* readability, requiring it for proper parsing is a pain in the !@$. Specific example -- you want to temporarily comment out an if statement but have the body run all the time.. Can't do it without reindenting.

    48. Re:Why perl? by skids · · Score: 1

      While it can be used to override operators, generally the intent is to create new operators. In either case the operators can be lexically scoped to contain then to their intended use scope.

      The semantic-preservation philosphy is alive and well in Perl6.

    49. Re:Why perl? by Bill_the_Engineer · · Score: 1

      What can perl do that newer languages such as python and ruby can't do, and do more readably/maintainably?

      You have it backwards. What do newer languages like python and ruby have that merits leaving Perl?

      When will "use strict" be available for Python?

      --
      These comments are my own and do not necessarily reflect the views or opinions of my employer or colleagues...
    50. Re:Why perl? by Anonymous Coward · · Score: 0

      open LINES " while(<LINES>) {
      if( $_ ~= / regex expression / ) {
      # Do something with the regex results
      }
      }

    51. Re:Why perl? by narcc · · Score: 1

      Look at that, you found a chart. Good for you.

      Statistically, what you say is just nonsense.

      You don't seem to understand that chart, the methodology, or statistics in general.

      Fun fact: Our little discussion here actually improves Ruby's TIOBE rank. Interesting, isn't it?

      Other similar sites show similar results.

      No, they don't.

      http://www.ohloh.net/languages/compare?measure=commits&percent=true&l0=java&l1=javascript&l2=-1&l3=python&l4=ruby&l5=-1&commit=Update

      https://sites.google.com/site/pydatalog/pypl/PyPL-PopularitY-of-Programming-Language

      http://www.google.com/trends/explore#q=ruby%20on%20rails

      http://lang-index.sourceforge.net/

      http://spectrum.ieee.org/at-work/tech-careers/the-top-10-programming-languages

      http://techcrunch.com/2012/09/12/javascript-tops-latest-programming-language-popularity-ranking-from-redmonk/
      ( http://redmonk.com/sogrady/2012/09/12/language-rankings-9-12/ )

      No one cared about Ruby before RoR -- and now that RoR has fallen out of favor (the fad is over) so will Ruby. Trends appear to show Ruby as flat or in decline.

      I know that you really like Ruby. That's fine. But let's not pretend that it's growing in popularity. It doesn't matter if the rumors about Ruby and RoR are true or not -- or that such-and-such criticism is just a myth or whatever else you want to bring up in defense of the language. The fact is that it's in decline and unlikely to ever again enjoy the hype it did years ago. Sometimes, being just the best thing ever in the whole of all history just isn't enough to make something popular.

      You seem to have a lot emotionally invested in the language (or other people's perception of the language). Just let it go, kid. In the grand scheme of things, it's not at all important.

    52. Re:Why perl? by narcc · · Score: 1

      No worries, I caught that.

      You may want to check out this article from earlier this year:
      http://www.drdobbs.com/mobile/the-rise-and-fall-of-programming-languag/232400093

      It was too old to make my earlier list (January 2012), but it's still quite relevant and informative. It should also help you make much better sense of the TIOBE data.

    53. Re:Why perl? by Anonymous Coward · · Score: 0

      yeah, perl 4 and perl 5.

    54. Re:Why perl? by gullevek · · Score: 1

      You can write shitty unreadable python code too. The fixed format layout of python doesn't really make it much better. Plus giving up on all the CPAN modules just to write python. I see no reason why.

      --
      "Freiheit ist immer auch die Freiheit des Andersdenkenden" - Rosa Luxemburg, 1871 - 1919
    55. Re:Why perl? by Jane+Q.+Public · · Score: 1

      "It was too old to make my earlier list (January 2012), but it's still quite relevant and informative. It should also help you make much better sense of the TIOBE data."

      I disagree on several levels. Not only is it a year old (2011 data is all they claim), it does not agree with TIOBE at all.

      Look at this comparison chart of many of the same languages as in the TIOBE Index. Just for one example, you can see that their results for Objective-C (which they should roughly agree upon, if they were going to agree on anything) are not even remotely similar.

      Further, I repeat: Ruby has only been in popular use for a bit over 5 years now. Maybe 6 at a stretch. That makes it the youngest of the bunch.

      I don't find that this informs me about the TIOBE Index at all. Rather, they simply disagree. At least one of them is way off.

    56. Re:Why perl? by Jane+Q.+Public · · Score: 1

      "You don't seem to understand that chart, the methodology, or statistics in general."

      Apparently I understand them better than you do.

      (1) Ohloh disagrees with TIOBE rather drastically. One or the other is wrong. Which one is hard to say, but TIOBE has a pretty good reputation in the industry.

      (2) Your Python data shows a difference between 2011 and 2012. I clearly referred to differences between 2007 and 2012. In case you didn't know, there is a pretty big difference. The graph on that Pydatalog page also disagrees with both TIOBE and Ohloh. Which is correct?

      (3) Your third link is about Rails, not Ruby. Again, there is a rather large difference. They are far from the same things.

      (4) Your 4th reference shows, just as TIOBE (and I) stated, that Ruby is up in popularity this month. It also divides languages into "general purpose" and "scripting" languages, which is pretty much an obsolete designation these days. It appears that what they really mean is compiled versus interpreted. However, there are at least a couple of different ways to compile Ruby today (JRuby being just one example).

      (5) Your 5th reference claims to show a graph of the TIOBE Index but the graph is actually nothing at all like the actual TIOBE index. Therefore I have to question the rest of their data as well. In addition, like some of the other references you gave, it doesn't show trends, which was the whole topic under discussion.

      (6) As far as TechCrunch is concerned, NOBODY else comes even close to agreeing with their results. (But then, what they chart there is not at all the same as what the others are claiming to chart.) So who is right? However, TechCrunch DOES show Ruby right up there at the top, higher than Perl and very near C. And TechCrunch does support my assertion that Objective-C came from near the bottom to near the top in recent years.

      Now, what was it you wanted to teach me about statistics?

    57. Re:Why perl? by narcc · · Score: 1

      I disagree on several levels. Not only is it a year old

      I wrote:

      It was too old to make my earlier list (January 2012)

      To which you replied:

      I don't find that this informs me about the TIOBE Index at all.

      I'm not surprised. You don't seem terribly interested in the data at all.

      Again, if you look at the data from the past few years, you'll see that Ruby is at best flat, and likely still in decline. I've offered my opinion as to why it's in decline.

      You can disagree with my opinion all you want, and you can disagree with the methodology of the various sources. That's fine, and we can have a discussion about that.

      You can't, however, argue the fact that the data presented shows Ruby to be flat or still in decline. The data that we have does not in any way show that ruby is growing -- quite the opposite, in fact! According to the TIOBE index, that you seem to favor, it has been steadily declining since 2009 and started to flatten out this year.

      I know that you like ruby, and that ruby is important to you. I'm sorry that it's not as popular as you'd like. That's not my fault. It's also not relevant to the question: "Is ruby in decline?" Unless you disagree with the data, the answer is clear.

    58. Re:Why perl? by narcc · · Score: 1

      Completely untrue. Here [ruby-forum.com] is documentation of someone complaining about a potential regression error in step for ranges when Ruby went to version 1.8.6. So obviously it existed even before then.

      Yep, I was off a bit. I couldn't remember the exact version, so I did a google search and trusted a forum post. Anyhow, it turns out it was added in 1.8.0

      Cool! An official source:
      http://ftp.ruby-lang.org/pub/ruby/1.8/changes.1.8.0

    59. Re:Why perl? by Jane+Q.+Public · · Score: 1

      "I'm not surprised. You don't seem terribly interested in the data at all."

      It depends on whose data you are looking at. But I repeat: at least two sources said Ruby was UP in popularity last month. That is the statement you seem to have been arguing with (either than or my claim that Ruby is not "niche")... I made no significant claims about its performance over a period of years. Yes, it does show rather flat, according to at least some of those datasets. But in others, no. Once again, according to your own reference: Redmonk (via TechCrunch) shows Ruby to be well ahead of Perl and almost even with C. Are YOU ignoring THAT data?

      I suppose it depends on who you want to believe.

      "You can't, however, argue the fact that the data presented shows Ruby to be flat or still in decline."

      I most certainly can. Once again, Redmonk shows it well above Perl, and both TIOBE and one other reference of yours show it to be UP in popularity last month.

      "I know that you like ruby, and that ruby is important to you."

      That is completely irrelevant. In my opinion, looking at your own data, I think you are showing significant "confirmation bias".

    60. Re:Why perl? by Lodragandraoidh · · Score: 1

      For me:
      I was a long time perl developer - until I found python. There isn't anything I can think of that can't be done in python that can be done in perl (or awk or sed for that matter). Furthermore, the base libraries provide most of the functionality needed, and I've found that I was able to avoid having to download modules - as I was building my own toolset most of the time.

      Other aspects sold it for me: faster and more accurate debugging, more readable code (regardless who wrote it - primarily because for most things there is only one canonical way to do something), ability to not only do small apps well - but to manage large applications easily, OO integrated into the language (not a sidecar - I never did get the hang of using OO in perl whereas python OO was natural to me), and finally there were some things that were 'pythonic' ways of doing certain equivalent perl tasks that ended up being superior.

      In summary: for me developer time and delivered working code is the bottom line - and python allows me to save time while delivering quality working code. You even have the option of building python modules in C if you desire - to address a performance bottleneck presumably. For what I do - I haven't had the need to do that yet - so whatever performance hits 'stock' python may have, it hasn't been a big enough problem to stop using it.

      YMMV

      --

      Lodragan Draoidh
      The more you explain it, the more I don't understand it. - Mark Twain
    61. Re:Why perl? by narcc · · Score: 1

      I give up. The TIOBE data very clearly shows ruby to be in a long decline which has flattened out in the last year.

      It's obvious to anyone capable of looking at the chart. I honestly don't see how you can continue to deny this, or why you'd even bother.

      Then again, you don't seem to be terribly good at paying attention:

      As far as TechCrunch is concerned,

      TechCrunch is reporting on RedMonk's language ratings. I included that link as I thought that a simplified exposition would be helpful. I guess I was wrong...

      Now, what was it you wanted to teach me about statistics?

      How about we start with this: A single data point does not indicate a trend. You need lots of points over time for that.

      Again, all the data suggests that ruby is either flat or in decline. The TIOBE data shows that it's in decline and starting to flatten out (that's not growth) The data from RedMonk show Ruby to be flat (that's not growth). The data from Ohloh suggest that ruby is either flat or in slight decline. (They're NOT "dramatically different" at all. I'd say they agree remarkably well, especially considering that their methods for determining popularity are so dramatically different!)

      Your 5th reference claims to show a graph of the TIOBE Index but the graph is actually nothing at all like the actual TIOBE index.

      It's not my fault that you're having trouble interpreting the chart.

      Your third link is about Rails, not Ruby. Again, there is a rather large difference. They are far from the same things.

      If you read my post, I suggested that ruby's rise in popularity and subsequent decline was tied directly to RoR. I thought it worth including as the search is also the most viable proxy for ruby. (Necessary, as using ruby by itself pulls in too much irrelevant data -- so much so that the chart runs nearly flat, as you would expect if you were searching for a common term like "emerald" or "gold" or "women".)

      Why is this so important to you? Why do you even care that ruby is in decline? Why this vehement denial? Accepting the TIOBE data as-is clearly shows that ruby is in a long-term decline that has flattened out over the last year.

      It's just a programming language. I promise, you'll get over it.

    62. Re:Why perl? by Lodragandraoidh · · Score: 1

      When I started having to have automation (either in my IDE or externally as a second pass) manage my curly braces and semicolons - coupled with strange debugging errors the result of dangling curly braces and/or semicolons - which sent me on many a 'needle in a haystack wild goose chase' to locate and fix - I knew there had to be a better way. I found it in python.

      For me: python saved me time, and allowed me to deliver more and better quality code over doing the same tasks in perl. When projects evolved to teams of people having to share and read each other's code - this really paid off. YMMV.

      If you are happy and productive with perl - stick with it by all means! If you are not - there are alternatives that may address the issues you are experiencing.

      --

      Lodragan Draoidh
      The more you explain it, the more I don't understand it. - Mark Twain
    63. Re:Why perl? by Lodragandraoidh · · Score: 1

      You could alternatively do something like comment out the original if statement and insert a passthrough:


      if True: # if myflag == 1:
              print "hello world!"
              myflag=2

      This code will have the desired effect (body of if statement runs every time) without having to unindent.

      "Can't do it without reindenting." O'RLY!!?

      --

      Lodragan Draoidh
      The more you explain it, the more I don't understand it. - Mark Twain
    64. Re:Why perl? by Jane+Q.+Public · · Score: 1

      "It's obvious to anyone capable of looking at the chart. I honestly don't see how you can continue to deny this, or why you'd even bother."

      I'm not the one who is not paying attention here. I didn't deny this at all. In fact I explicitly acknowledged (go back and read again) that some of those sources showed Ruby's popularity over the last few years to be rather flat. It's right there in black and white. Why didn't you see that, or pay attention to it?

      REPEAT: What I claimed was that Ruby was up LAST MONTH. None of your sources contradict that.

      "TechCrunch is reporting on RedMonk's language ratings. I included that link as I thought that a simplified exposition would be helpful. I guess I was wrong..."

      And once again: in my last post I mentioned that it was "RedMonk (via TechCrunch)..." but you apparently didn't see that either. Even so, proof that I understood who the source was is still there, in black and white.

      "Again, all the data suggests that ruby is either flat or in decline. The TIOBE data shows that it's in decline and starting to flatten out (that's not growth) The data from RedMonk show Ruby to be flat (that's not growth). The data from Ohloh suggest that ruby is either flat or in slight decline. (They're NOT "dramatically different" at all. I'd say they agree remarkably well, especially considering that their methods for determining popularity are so dramatically different!)"

      No, ALL the data do not. Once again, look at RedMonk's chart. REPEAT: it shows commits to Ruby projects to be above Perl and nearly level with C. This was data you referenced yourself.

      I'm not making claims like that of my own, but very clearly, ALL the data do not show what you claim.

      "If you read my post, I suggested that ruby's rise in popularity and subsequent decline was tied directly to RoR."

      I don't care. My post was about Ruby, not Rails, and that is what you were replying to. Perhaps your point about Rails is significant, perhaps not, but showing that Rails had declined means nothing unless you can SHOW that there is a cause-effect link between that and the popularity of Ruby. You have not done so; you have merely made a bald, unsupported assertion.

      " (Necessary, as using ruby by itself pulls in too much irrelevant data -- so much so that the chart runs nearly flat, as you would expect if you were searching for a common term like "emerald" or "gold" or "women".)"

      That is the weirdest argument yet. As an analogy, that is rather like saying you are using Shelby Cobras as a proxy for all Fords, because searching just for Fords pulls in too many results.

      "Why is this so important to you? Why do you even care that ruby is in decline?"

      Who said I cared about that? The only reason I have been contradicting you is because you have been making ridiculous arguments and then claim to have actually demonstrated your point, when actually you have done nothing of the sort. You could have been arguing about ant farms, I don't care. You didn't even contradict my original point. So: why are YOU so adamant about it, to the point of making logically absurd arguments (Rails proxy, indeed)??

    65. Re:Why perl? by narcc · · Score: 1

      It depends on whose data you are looking at.

      You're out of you mind. At least as far as Ruby is concerned, all the sources we've looked at are in pretty close agreement. Considering that the methodology is so different between some of them, it's pretty impressive.

      The claim I made was that Ruby was dying. The TIOBE data YOU provided showed exactly that -- a steady decline over a period of several years. It's true that it may be flattening out, we'll need to wait and see if the downward trend continues over the next year or two, if it remains steady, or if something miraculous happens to reverse the trend.

      You want to talk about the languages popularity relative to other languages (why?) I guess we can, though I honestly don't see the point. It's completely irrelevant to my claim that ruby is dying.

      C and Perl and the TIOBE data. Well, they're both ahead of Ruby in terms of overall popularity, with C way ahead of both. Horray? What's the point?

      I think you are showing significant "confirmation bias".

      It's not my fault the data confirm my earlier assertion. I'm sorry that reality doesn't fit your delusion.

      But I repeat: at least two sources said Ruby was UP in popularity last month.

      Up against what? The previous month? Nope, it's down... Oh, up from December last year? Yep, it's up a tiny bit from the same month last year. (See what I did there?)

      Why is that meaningless? Take a look at the chart from 2007 to early 2008. Notice those gigantic downward spikes and the crazy upward spike between them? Now, you could take this to mean that over a 10-month period people en-mass hated, loved, hated, and then loved ruby like they're townspeople in The Simpsons when faced with two competing salespersons, or you could go "huh, I guess that that data isn't terribly meaningful if we look at just a tiny bit."

      Pick any language you want, you'll see massive peaks and valleys. Well, relatively speaking -- it looks pretty big on the chart, but in Ruby's case, it's just a tiny tiny change. That it's "up" less than 1/4 of 1 point over the same month last year, in data where a several point swing down and back up (or vise versa) happens rapidly and regularly, I think we can safely assume that there was no significant change there. If yo believe that the data is so accurate that it can detect perfectly such a minute shift in popularity, I can't help you any more than I can help the citizens of Springfield who apparently make up the bulk of those posting about programming languages.

      Redmonk (via TechCrunch) shows Ruby to be well ahead of Perl and almost even with C. Are YOU ignoring THAT data?

      "Well ahead" is just delusional. It's not. If ruby is "well ahead" of Perl then it's "well behind" C by the same absurd reasoning. I'm guessing that you haven't even looked at the raw data, so I'm probably just wasting my time here, but they're actually pretty close to each other, within a couple points. You also probably don't know that the chart isn't designed to rank languages by popularity. Not that it matters to you. You don't care what the data says -- because the data doesn't show you what you want to see. It shows that ruby has been declining in popularity for years.

      I'm too tired to bother with this any more. The data is in. Ruby is declining. Get over it.

    66. Re:Why perl? by narcc · · Score: 1

      I'm not making claims like that of my own, but very clearly, ALL the data do not show what you claim.

      I claimed that ruby was in decline. The data from RedMonk does not show a trend as it's a single snapshot. If you look at previous iterations of that chart, there does indeed appear to be a decline, though there isn't really enough data there to show the clear downward trend you see on other sources.

      The only reason I have been contradicting you is because you have been making ridiculous arguments and then claim to have actually demonstrated your point, when actually you have done nothing of the sort

      Well, my only claim was that Ruby is in decline. The data show this. You just hate the facts.

      That is the weirdest argument yet. As an analogy, that is rather like saying you are using Shelby Cobras as a proxy for all Fords, because searching just for Fords pulls in too many results.

      That's because you're clearly incompetent, as evidenced by your ridiculous analogy. It's not my fault that you're are incapable of understanding why a search for Ruby on that site won't tell you anything relevant to the discussion yet a search for "ruby on rails" will. It's painfully obvious. I honestly don't see why this is so damn difficult for you.

      Perhaps your point about Rails is significant, perhaps not, but showing that Rails had declined means nothing unless you can SHOW that there is a cause-effect link between that and the popularity of Ruby.

      More incompetence. First, you don't prove causality. Hell, in this case, it's obviously impossible! It's so obvious that it would make an excellent classroom example. Go learn how basic science works.

      My reasoning is obvious. Ruby's rise in popularity correlates with the rise of RoR. This isn't in dispute. The clear and obvious decline in popularity of Ruby correlates with the decline in popularity of RoR. You can see this reflected in the TIOBE index and the Google Trends search.

      You have not done so; you have merely made a bald, unsupported assertion.

      What? The claim was that ruby was declining in popularity. That's pretty clearly true. The data you provided makes a very compelling case! Do you mean my opinion as to why it's declining? I offered my reasoning for that already. I believe more than once. It's just my opinion, but it does have real data behind it -- I'd hardly call that unsupported -- it's more like "informed" as in "my informed opinion".

      You didn't even contradict my original point.

      This was your original point: "According to the TIOBE Index, Ruby moved up on the list again this month." Which was intended to suggest that Ruby was not, in fact, dying. With Ruby clearly in decline, I failed to see the relevance as the rank is absolutely meaningless in this context. You seem to understand how it's position on the list can change regardless of its popularity when you write "But that's largely because Objective-C came out of nowhere".

      Your "argument" against my claim was perfectly meaningless. You know this as well as I do. Yes, Ruby did change position on the TIOBE rank. What's the point? It's not dying any less just because JavaScript suffered one if its typical massive spikes, in a downward direction this time, knocking itself below Ruby a few months back. The downward trend is clear as crystal.

      What a massive waste of this this has been.

    67. Re:Why perl? by Jane+Q.+Public · · Score: 1

      "I claimed that ruby was in decline."

      No, you claimed that Ruby was, in your own words, "... a dying little niche language" that nobody cared about. Your own figures show that to be false. Sure, maybe it's in very slightly less use than it was a few years ago, but it's hardly dying, and there is a rather large (in an absolute, not comparative sense) community of developers who do care about it.

      "The claim was that ruby was declining in popularity."

      Stop moving the goalposts. You did not. You claimed that it was dying and that nobody cared about it. Yet you have shown nothing of the sort.

      "This was your original point: "According to the TIOBE Index, Ruby moved up on the list again this month.""

      Which is pretty clearly true, according to TIOBE itself and your own references. And none of your extensive ranting refutes that.

      "Which was intended to suggest that Ruby was not, in fact, dying."

      I see. So you are reading minds now, too? Incredible.

      "With Ruby clearly in decline..."

      I did not dispute that Ruby was relatively flat or may have even declined (actually, according to your own charts, it's stayed pretty flat if you ignore a few short-term spikes). That was never my argument, and I clearly stated as much several posts ago. But that wasn't YOUR original argument. MY argument with you is that it isn't dying, and there are lots of people who care about it. But I see that I was just feeding a troll.

      "The downward trend is clear as crystal."

      No, it is not. By YOUR OWN data. If you look at the charts, it is roughly the same as it has been for several years, if you ignore some short-term spikes in the charts. Just as you proposed to do for JavaScript. If you can ignore some short-term spikes for JavaScript, then I can do the same for Ruby. You can't have that both ways.

      There may still have been a very slight decline even if you ignore the spikes, but it is hardly significant.

      "The data from RedMonk does not show a trend as it's a single snapshot."

      Hah. But YOU tried to argue earlier that another shapshot was valid. I pointed that out quite a while ago. If you can do it, so can I. You can't have these things both ways, man.

      "What a massive waste of this this has been."

      I agree with that completely.

    68. Re:Why perl? by ThePhilips · · Score: 1

      but most Perl "developers" are scripters, not programmers

      This is, quite possibly, the stupidest thing I've ever read -- and I've been known to read the comments section on World Net Daily articles.

      Yet it is true. Most Perl programs are too short to be called programs and are called scripts instead.

      That is also helpful sometimes. I once write a program to repair proprietary binary files. Management immediately shot it down: we do not provide to customers stuff like that. But then I rewrote it in Perl and called it a script - and alas there are no limitations what we can do with the scripts!

      --
      All hope abandon ye who enter here.
    69. Re:Why perl? by Anonymous Coward · · Score: 0

      as the A/C, I can say that I have absolutely nothing against Larry Wall or his achievements -- he seems like your classic Unix hacker, and a very successful one at that. I'm just no fan of the language.

    70. Re:Why perl? by Anonymous Coward · · Score: 0

      I'm sorry you insist on only seeing the superficial case, then. protip: "scripting" as in "combining other stand-alone utilities to obtain emergent functionality" in opposition to "programming" as in "obtaining functionality through native combination of platform-provided utilities" -- parsing the output of ls is scripting, calling readdir(3) in a loop is programming. must be nice always being the smartest guy in the room, huh?

    71. Re:Why perl? by Frequency+Domain · · Score: 1

      Thanks for the response. Your experience pretty much mirrors mine, except I went for Ruby instead of Python.

    72. Re:Why perl? by chromatic · · Score: 1

      I never did get the hang of using OO in perl whereas python OO was natural to me....

      ... which is amusing because other than the surface syntax, the object models are so similar that they have the same fundamental and simplistic flaws.

    73. Re:Why perl? by david_thornley · · Score: 1

      Man, you don't know what the old COBOLs had (I know nothing of the evolution of the language in the past thirty years or so).

      The data structures were laid out byte by byte, so it was possible to MOVE something to something else with totally different internal structure. Alternatively, MOVE CORRESPONDING with some of the subobjects named the same (and therefore moving) and some named something different in a hard-to-spot way.

      A "paragraph" was a collection of one or more "statements" with a label attached. You could make this as fine-grained as you liked. You could then write PERFORM ... THROUGH ... statements, meaning that your subroutine calls had not only specified entries but specified exits, so you could overlap them as you liked. Of course, there were no local variables, but you really don't need them for obfuscation.

      And, of course, the "ALTER" verb to change labels of "GO TO"s.

      I think I could have written great obfuscated COBOL, even better than what one of my colleagues wrote for production.

      --
      "When you have eliminated the unacceptable, whatever is left, however improbable, must be the truthiness" - Holmes
    74. Re:Why perl? by DaveAtFraud · · Score: 1

      I managed to not actually do any COBOL programming back when (early 1980s). I did get to experience the joy of getting a COBOL program to call a FORTRAN program with some significant data structures in common blocks (thankfully, I forget what COBOL called them). I just remember that arrays were handled differently internally. This was all on an IBM System 370.

      Cheers,
      Dave

      --
      They that can give up essential liberty to obtain a little temporary safety deserve neither safety nor liberty.
      Ben
    75. Re:Why perl? by Anonymous Coward · · Score: 0

      Making whitespace significant in a language is something that some people like and some do not

      I use this as an interview question. I've noticed a strong correlation between coders that don't mind python's whitespace rules and coders that naturally write clean, readable code. I'd rather hire a tidy coder that produces twice as many bugs over a messy coder because those bugs cost a fourth as much to debug.

    76. Re:Why perl? by narcc · · Score: 1

      You claimed that it was dying and that nobody cared about it.

      A language in decline is dying. The data shows Ruby to be in a long decline, spanning several years. You're insane.

    77. Re:Why perl? by Frequency+Domain · · Score: 1

      A language in decline is dying. The data shows Ruby to be in a long decline, spanning several years. You're insane.

      In an expanding market a given item can have a declining market share and still be experiencing growth. Apple sells more iPhones than ever even though its share of the smartphone market has declined. The same logic can apply to programming languages as well as commodities.

    78. Re:Why perl? by Jane+Q.+Public · · Score: 1

      And you're trying to get in the (nonsensical) last word.

      LISP has been declining for decades. Is it dead? How about SmallTalk?

      Long ago, assembly language was pretty far up there in the list. It is much lower down now, but (for obvious reasons) it is in no danger of dying.

      Java has been in steady decline since about 2000. Is it dead?

      C (according to Ohloh and less so TIOBE) has been in in rather sharp decline since 2006. Is it dead? In danger of dying?

      You're full of nonsense.

      According to the TIOBE graph, Ruby is almost exactly where it was in mid-2007. Using YOUR own source, Ohloh, in order to get a more visible scale, I graphed just Ruby. And guess what? Sure, it's a bit down from 2010, but it's about where it was in mid-2009, and way ABOVE where it was in 2006 and 2007. Again: if you can ignore some spikes in the JavaScript graph, I can ignore some short spikes in the Ruby graph.

      I keep tellin' ya, man. You aren't reading the actual data properly. Go ahead and think I am insane if you want to. I'd be willing to bet I got better scores in my university statistics classes than you did.

    79. Re:Why perl? by Jane+Q.+Public · · Score: 1

      By the way: here is that graph I mentioned. From your own source.

    80. Re:Why perl? by narcc · · Score: 1

      According to the TIOBE graph, Ruby is almost exactly where it was in mid-2007. Using YOUR own source

      You brought in the TIOBE graph, not me. Also, the TIOBE graph shows Ruby to be in a steady decline. I don't know why graphs confuse you so much.

      Yes, LISP and SmallTalk are effectively dead. Java is in decline and, yes, it's dying. That happens to programming languages all the time. This isn't rocket science.

    81. Re:Why perl? by Anonymous Coward · · Score: 0

      No one cares about ruby. It's a dying little niche language

      That's interesting... From what I can see, thousands of new companies are using Ruby (generally Rails) as the foundations for their businesses which investors are pouring millions and millions of dollars into. Now, that doesn't necessarily make the language itself good or bad, but you can bet that it's going to be around in full-force as long as new web applications are popping up. Unless your claim is that web applications are going to go by the wayside? If not that, then what language do you think they'll be written in?

      I understand you have some gripes about what's included in the language, but if you're willing to overlook parts of Perl's syntax than certainly you can expand your vocabulary slightly to include some of Ruby's idioms.

      I write largely Objective-C, Ruby, and JavaScript code these days, though I first learned to program on C/C++/Perl. I think Perl is certainly underrated amongst those who haven't given it a chance, but I've found Ruby to be equally as suitable for every string manipulation/data munging task that I've been put up against. For those speaking of CPAN, RubyGems itself is also massive and the community is quite active about testing, sharing, and education.

      I'm guessing that maybe it feels good to sling some mud on Ruby and Python as in my experience the members of those communities love to shit on Perl. But that doesn't make your points any more valid.

    82. Re:Why perl? by guacamole · · Score: 1

      You're setting up some kind of straw man argument here. (What can C/Java/Common Lisp/Python do that others can't do?) But I'll reply anyways.

      1. CPAN libraries for the most part are excellent. Great code to use in your project or learn Perl coding from.

      2. Have it occurred to you that some Perl _like_ Perl syntax? What looks unnatural to you is 100% natural code to others. Perl is great language for people who live in breath Unix. If you look at the Unix in the 80/90s, the standard way to program it was in either C or shell script (sh, csh, etc) combined with standard unix utilities like sed, awk, grep, etc. Shell scripts were ad-hockish and didn't scale well beyond a few dozen lines of code. C could do anything but was also a pain to code in, specially for simple tasks and text processing. Perl4 bridged all of these tools together in a single language. Perl5 added OOP, modules, and complex data structures.

      3. Perl brought us the "Perl regular expressions", which have been widely imitated and copied by others. Perl's regular expressions are still top notch, and Perl 6 will introduce an alternative regexp system.

  11. Crucially by Anonymous Coward · · Score: 0

    He doesn't forsee a time when Perl 6 is ever released.

  12. Commence! by interval1066 · · Score: 1

    Let the obfuscated congratulations begin.

    --
    Python: 'And then suddenly you have a language which says "we're all stuck with whatever the whiniest coder wants".'
  13. And here is the birthday cake by perl6geek · · Score: 4, Informative
  14. hmmm by HPHatecraft · · Score: 1

    the "guy before me" left a lot of undocumented Perl code. Some short scripts, some that are pretty involved.

    I wonder how much easier it would be to understand the code were had the scripts been written in something else? Python?

    On one hand, this is cool -- this is just the excuse I needed to learn Perl -- it is my job. On the other, it pisses me off that there are virtually no comments.

    From an outsider perspective (not a Perl master at this time), Perl seems to me to be a distillation of Unix, albeit filtered through the idiosyncrasies of Larry Wall; the gift of Perl is brevity (and not having the declare the size of an array is pretty sweet, too).

    1. Re:hmmm by preaction · · Score: 3, Informative

      As a Perl master, I agree with your perspective: Perl is the UNIX philosophy taken past its logical conclusion. It is more logical than shell scripts, more terse than C, greater than both for the everyday tasks that befall a serious computer user (and absolutely essential for a UNIX administrator).

    2. Re:hmmm by Anonymous Coward · · Score: 0

      I suppose one thing I could say is that I'd rather untangle obfuscated Perl than obfuscated C. that said, it frequently seems like Perl is obfuscated by design, while C is only obfuscated by the deviant (and those participating in the IOCCC). Python's verbosity gives it a few readability advantages: namely that it looks like pseudo-code, which most everyone can read. the maxim of least surprise goes a long way.

    3. Re:hmmm by Anonymous Coward · · Score: 0

      no. no compiled language that I'm aware of is "terser" than C -- you have direct memory access. if you want to be completely balls-out insane, you can write completely inscrutable code that does nothing but pushes the right bits onto the right registers at the write time, the net effect being all sorts of craziness depending on OS. of course, it requires true "mastery" of a single platform.

      and, unless your name is Larry Wall (or, better, Audrey Tang -- let's use the preferred name), I would hesitate to call yourself a "master."

  15. Re:Python, please by smittyoneeach · · Score: 2

    if __name__=="__main__",
    you'll get your turn, Guido.

    --
    Get thee glass eyes, and, like a scurvy politician, seem to see things thou dost not.--King Lear
  16. Difficult to understand? by benjfowler · · Score: 1

    My first exposure to Perl was 15 years ago, when I was doing 'web' programming (actually, writing dinky CGI scripts), using some really primitive library (at the time, CGI.pm was "advanced")

    Maybe I'm just thick, but coming from more conventional language, I never 'got' context, or how to do OO properly in Perl. I simply was never able to form a mental model of how to use it correctly.

    I never did use Perl for personal coding after that (went straight to Python, because at least I could get my head around the syntax and type system).

    1. Re:Difficult to understand? by ThePhilips · · Score: 2

      I simply was never able to form a mental model of how to use it correctly.

      Perl is a multi-paradigm language. It doesn't bundle or insist on a particular model - you are free to use whatever model you want.

      --
      All hope abandon ye who enter here.
    2. Re:Difficult to understand? by careysub · · Score: 1

      Perl is a multi-paradigm language. It doesn't bundle or insist on a particular model - you are free to use whatever model you want.

      And herein lies the problem - program maintenance, which is normally counted as 80% of the cost of software life cycle.

      Any language that prides itself on having lots of ways of doing any task or operation, and has many programming models to choose from means that when maintaining legacy code, you must asymptotically approach learning all the ways of doing everything, and all the paradigms, often mixed together, because the vanished legions of programmers that came before are the programming equivalent of a million monkeys.

      Context dependent interpretation of the meaning of operators combined with operator over-loading creates tremendous problems with reading code others of written with any certainty of correct understanding.

      Far too much attention is paid to aspects of tools that making the fun, easier part of programming (writing new code) more fun and easier, while making the long pole in the tent, maintenance, longer and heavier.

      The truth is we must deal with middle of the road to lowest denominator programmers and their work constantly, and defenses of languages that they are easily understood when written by gurus (and read by other gurus) is really an indictment not a defense.

      I've done a fair amount of APL and Perl programming, rather liked them when writing with them, but am under no illusion that they tend toward comprehensibility or maintainability.

      --
      Starships were meant to fly, Hands up and touch the sky - Nicky Minaj
    3. Re:Difficult to understand? by ThePhilips · · Score: 1

      Context dependent interpretation of the meaning of operators combined with operator over-loading creates tremendous problems with reading code others of written with any certainty of correct understanding.

      Having recently parsed huge pile of financial Java code (Java doesn't support operator overload) which uses arbitrary precision numbers, let me tell you that the other side of what you describe isn't particularly rosy. In fact, even simple financial formula, in language like Java, with arbitrary precision number library, degrades into a monstrous clusterfuck of code which can be barely understood even under debugger. Compare with C++ or Perl: the math formula can be expressed literally as on paper.

      The truth is we must deal with middle of the road to lowest denominator programmers and their work constantly, and defenses of languages that they are easily understood when written by gurus (and read by other gurus) is really an indictment not a defense.

      That is a bull. One of the weakest developers in my department is in fact seasoned Perl programmer who has no problems reading through my 1-3 liners. (Though he has problems writing his own analogue in any language.)

      You can quote as a problem relative unpopularity of Perl and resulting unfamiliarity of majority of developers with it. But, please, not again the old bull that it is hard to read Perl programs.

      And herein lies the problem - program maintenance, which is normally counted as 80% of the cost of software life cycle.

      As long term support goes, programming language or coding styles do not really matter that much. That is small stuff. Misapplied (or simply outdated!) top level tactics and global strategies, and resulting from them faults, problems and design gaps, are independent from programming language and are the major problem of the long-term maintainability of the code. They easily account for 80% of time spent on maintenance(*): because you can't easily close (or occasionally even forbidden to) close design gap in stable product; have to resort to piles of workarounds all over the place and then spend disproportional amount of time fighting the side-effects of the workarounds.

      (*) And that is 80% which come out after the larger 80%: lion share of work maintenance does is trying to figure out what precisely customer is complaining about.

      --
      All hope abandon ye who enter here.
    4. Re:Difficult to understand? by Anonymous Coward · · Score: 0

      You're just slow and stupid

  17. -1 troll by Anonymous Coward · · Score: 0

    which perl? the one that everyone uses and the author abandoned or
    perl 5?

  18. Oh noes by korgitser · · Score: 1

    the rise in mobile devices will continue and Perl will need to evolve to work with that

    Does this mean Perl is considering to jump on to the tablet bandwagon? I cannot even imagine what that would mean for a programming language. All I do know is that we have lost many a great seamen to the sirens of tabletia. Shipwrecks, shipwrecks everywhere.

    --
    FCKGW 09F9 42
  19. Re:I used it. Once. by Anonymous Coward · · Score: 0

    a good example of why perl is awesome

  20. To my favorite programming language by colin_faber · · Score: 1

    eval unpack u=>q{E')I;G0@7%[2&%P'D@0FER=&AD87D@4"%;GT[97AI=}

  21. libraries first by bzipitidoo · · Score: 2

    When considering a new project, I look first for libraries I want to use. CPAN has the most commonly used ones, but get a little obscure, and you're out of luck. For instance, CPAN has OpenGL, but not OpenSceneGraph. Then I find out what languages interface with them. It quickly narrows down until maybe one language is left, and most often that language is C/C++. Sometimes no languages are left, and then I have to decide if I want to go through the pain of linking multiple languages, or search for more libraries. I like Perl's data types and regular expressions, but the pain of interfacing with a C library is greater than the convenience of not having to hack up custom hash functions and not bother with dynamic memory management. At least there's PCRE.

    Perl 6 is supposed to address this issue. Seamless interfacing with any C/C++ libraries. If it works, would make a lot of CPAN redundant. Been waiting for Perl 6 for years now.

    --
    Intellectual Property is a monopolistic, selfish, and defective concept. It is "tyranny over the mind of man"
    1. Re:libraries first by skids · · Score: 2

      Been waiting for Perl 6 for years now.

      There's enough of it working now to start toying around. The "NativeCall" interface got to draft standard status recently, and works, mostly. Lack of many C ("native") data types will be a point of pain for some time to come, though.

    2. Re:libraries first by jandrese · · Score: 2

      Perl 6 has the worst case of second system effect I've ever seen. They said at the outset that Perl 6 was going to be a major rewrite, but I never expected to still be using Perl 5 in 2013. It's a shame too because Perl has some definite rough edges, especially with complex data types and writing object oriented code. The complex data type thing is a big one, most programmers really struggle with how to define a hash of references to arrays or anything like that, and the syntax for accessing or updating said objects quickly becomes nightmarish.

      --

      I read the internet for the articles.
    3. Re:libraries first by FacePlant · · Score: 3, Insightful

      Are you using 5.16.2?
      Are you using Moose/Mouse/Moo for complex data types and/or object oriented programming.?

      Perl is alive and well.

      If you think of 5 as being a syntax identifier, then you might be pleased to see all of the development that's gone on since Perl 4 gave way to Perl 5.

      It sounds a little bit like you're complaining that Perl's development has not followed your idea of semantic version numbering.

      --
      My Heart Is A Flower
    4. Re:libraries first by Anonymous Coward · · Score: 0

      I reckon that nightmarish data structures become less of a nightmare with temporary variables.

      my $thing = $some->{horribly}->{far}->[2]->{complex_data_structure}->{maybe}->{from}->{XML::Simple};

      foreach my (@$thing) { get_to($_) } ...

      bonus points for spotting the perl best practices pun in the code sample.

  22. Perl 6? by kriston · · Score: 3, Insightful

    Okay, so let's have a roll call of those of us using Perl 6 in production.

    Hands?

    Anybody?

    --

    Kriston

    1. Re:Perl 6? by Anonymous Coward · · Score: 0

      Just leavin' this here ... http://developers.slashdot.org/story/00/07/19/203221/larry-wall-announces-perl-6

    2. Re:Perl 6? by Anonymous Coward · · Score: 0

      I never put vaporware into production.

    3. Re:Perl 6? by onefriedrice · · Score: 1

      Okay, so let's have a roll call of those of us using Perl 6 in production.

      Hands?

      Anybody?

      In production? There probably shouldn't be any hands, but I'm sure there are.

      Perl 6 is nifty, but I would still call it "academic" at this point. Fortunately Perl 5 is still rock solid, and it is still a wonderful choice for many production applications.

      --
      This author takes full ownership and responsibility for the unpopular opinions outlined above.
    4. Re:Perl 6? by perl6geek · · Score: 1

      Reports of Perl 6 in production are slowly trickling in on the #perl6 IRC channel, but currently it's only a handful. Even I as a Perl 6 compiler developer don't recommend its production usage yet. But for learning the language and small one-off tasks it's already very nice, and getting nicer each month.

  23. Re:I used it. Once. by Hatta · · Score: 2, Interesting

    Sounds like Perl. Powerful, accessible to a complete beginner, reliable, and practically unmodifiable once written.

    --
    Give me Classic Slashdot or give me death!
  24. Advantages of Perl by Animats · · Score: 2
    • Better syntax than Bourne shell scripts.
    • Preinstalled on most servers.
    • Programs from 1998 still run. (Unlike Python, where the Little Tin God keeps making incompatible changes.)
    • The CPAN library has some quality control and maintenance.
    • No vendor can make it go away.
    • Fast regular expression processing.
    • Closures! Although most Perl programmers don't know that.

    The syntax is unreadable, of course. And Perl 6 seems to have been rejected by the market. Still, it's a vast improvement over shell scripts.

    1. Re:Advantages of Perl by Maximum+Prophet · · Score: 2

      That, I think is the key to why Perl is still around.

      Shell scripts are quick and easy, they work and play well with others, but they quickly get unmaintainable after a page or two.

      Perl has local variables, real functions, and it also works and plays well with others.

      You really can do 90+% of everything you might want to do in Perl. Add in C code if you need something to be very fast, and you're up to 95+%. Well written Perl is no less readable than any other computer language, and more readable than most.

      --
      All ideas^H^H^H^H^Hprocesses in this post are Patent Pending. (as well as the process of patenting all postings)
    2. Re:Advantages of Perl by jgrahn · · Score: 1

      Better syntax than Bourne shell scripts.

      For the old Bourne shell I agree, but IME bash syntax can be distinctly better than Perl for certain tasks -- typically stuff that's rather heavy on glueing other stuff together. And bash is becoming universally available, too.

    3. Re:Advantages of Perl by jandrese · · Score: 1

      I don't think Perl 6 has been rejected by the market, it's just never been finished. It seems like an endless project for Larry and company to tinker with Perl 6 until they get it "right" before it is ready for us mere mortals. I've certainly never seen anybody go "Ok, Perl 6 is ready, you should start porting your scripts now."

      --

      I read the internet for the articles.
    4. Re:Advantages of Perl by greg1104 · · Score: 2, Insightful

      Programs from 1998 still run because the language has been stagnant ever since. Python breaks because it actually improves sometimes. "The main power of Perl has always been its ability to quickly adapt"...seriously? Perl 6 has been stuck in R&D hell for a dozen years now. Even the Duke Nukem Forever team is starting to feel awkward about how long it's taking.

    5. Re:Advantages of Perl by Anonymous Coward · · Score: 1

      Since the Perl 6 project started, various features have been backported to Perl 5, including, but not limited to:

        * new keywords (say, given, when, state)
        * Unicode support
        * smart matching (feels like an .equals() method, works more like pattern matching in functional languages)
        * the Moose object system (actually not core Perl, but quite important)
        * thousands of other new modules, adding to the available language

      The remarkable thing is that most of these additions could be made in a backwards-compatible manner across versions 5.x. Perl is expressive enough to model the concepts of other languages without having to break. There remains, however, the matter of this hideous syntax . . .

    6. Re:Advantages of Perl by dbIII · · Score: 2

      I was going to dust off what little I knew about python to do some trivial selection boxes that would set environment variables, but then I just added "zenity" to bash and it did the job very well in a very short script.

    7. Re:Advantages of Perl by Mjlner · · Score: 2

      Programs from 1998 still run because the language has been stagnant ever since.

      You really have don't know anything about Perl, do you? To suggest that Perl has been stagnant from 1998 (v. 5.005) until now (v. 5.16.2) is ridiculuous. The difference is immense. That doesn't mean that backwards compatibility needs to break. You just don't know Perl or its evolution.

          Python breaks because it actually improves sometimes. "The main power of Perl has always been its ability to quickly adapt"...seriously? Perl 6 has been stuck in R&D hell for a dozen years now. Even the Duke Nukem Forever team is starting to feel awkward about how long it's taking.

      Lessee.... Python 3.0 came out 4 years ago. Still, 2.7 is the one installed by default across the board. Some distros (e.g. latest Red Hat) are still stuck on 2.6. Apparently, most people can do without the improvements in Python 3.0-3.3.

      And Perl 6 is another language altogether. Perl 5 will continue to evolve long after the Perl 6 becomes mainstream. I think Larry Wall made a big mistake in using the same name, honestly. But still, you just don't know Perl.

      --
      Lemon curry???
  25. Re:I used it. Once. by arielCo · · Score: 1

    That's partly because it was your first (or one of your few) programs in Perl. You likely made things more complicated than needed for lack of knowledge and experience.
    I've always said that Perl is a good fit for programmers who can recall dozens of "idioms" (memes), and keep their understanding of its unique semantics fresh. Things like keys %{ {map {$_=>1} @list} } (implementing unique(@list)) and internalizing that every expression is ultimately evaluated as a list. Some are silly, but there's little argument about its expressiveness and flexibility.

    --
    This post contains no rudeness or derision of any kind. All arguments are friendly. Terms and exclusions may apply.
  26. And.. C turned 40 by Anonymous Coward · · Score: 0

    I believe an honorable mention of C is needed if we're discussing anniversary years.

  27. Write-only. by Futurepower(R) · · Score: 1

    Some people say Perl is a write-only language that is slowly losing importance in comparison to Python. It seems that it is the CPAN library that is important, not the Perl language.

    1. Re:Write-only. by Anonymous Coward · · Score: 0

      fuck python and its tabs. i'll take an extremely flexible language that lets me write code however i want for a general purpose scripting language over python any day.

      before you jump on me, nerds, yes, for work it's obviously a different matter. i've never worked at a place that uses python. i'm sure it's great for some stuff. if i were doing something it's especially good at, i'd use it. haven't come across anything like that yet though.

    2. Re:Write-only. by Anonymous Coward · · Score: 0

      Write-onliness of Perl is more myth than reality.

      True story: The company I work for bought a license for Fogbugz for Unix some years ago. There was a problem with the Perl script they use to link submissions on CVS to their corresponding cases. I had to analyse it to find the problem, even as I haven't ever worked with Perl (and haven't since). It wasn't hard at all, once you know the basics.

      Too clever code is difficult to read and maintain, but that is true regardless of the language it is written in.

  28. she's dead by Anonymous Coward · · Score: 0

    I was waiting 4 years for Perl 6 to come, but she's barely a whisper in the programming world today. I think perl is simply too complex for the casual programmer. That complexity gives a lot of power. I was hoping for Perl 6 to fix the object oriented problems, but I gave up, and felt better. To this day, I still miss the power of perl.

  29. Limited by ecosystem more then capability by Anonymous Coward · · Score: 0

    Having been hard core perl for many years and built and sold businesses based on it I can attest that it is a capable platform. However, in my experience, good perl developers have become hard to come by and are typically more senior and hence more expensive. Additionally, perl (right or wrong) does not have a reputation in IT as cutting edge or capable and when seeking investment or taking a company to market gives the impression of development team stuck in ancient technologies for which few experts can be found. That and the tiresome nature of hack like coding fades to make perl more relevant (inside-out perl objects for example) prompted me to use python in my most recent undertakings and there is a palpable improvement in the ecosystem and respect level. Developer supply is a key determinant in which language and platform to use and sadly Perl's lack of sex appeal has become limiting.

  30. Perl as a refactoring tool by loufoque · · Score: 1

    Personally, I exclusively use Perl to re-factor C++ code with regular expressions.
    It's like a better sed.

  31. Perl is expressive by Okian+Warrior · · Score: 2

    Perl's strength is that it's expressive. It's not a language which is easy to learn or which generates heavily optimized code.

    In the demo phase, you're not really worried about performance. The goal is to have something working as quickly as possible, and not worry too much about how fast it runs, or how much memory it takes. Overspec your demo system for the time being (ie - make it really fast and install lots of memory), and once you have a reasonable interface go back and recode it in a simpler language which can be more easily optimized.

    Languages which are simple to learn (c++, for example) are generally not very expressive. You end up wasting tons of time debugging issues of memory allocation, library interface details, and datatype conversion.

    Languages which are expressive are a little harder to learn, but any individual line in the expressive language does a lot more. Since you are writing fewer lines, and since the fewer lines do more, you end up making programs more easily and in less time.

    Yes, the programs will execute a little slower, but as mentioned, this is not important in the demo stage. Your productivity will be much higher.

    And there are lots of places where performance simply doesn't matter. Scripts usually fall into this category.

    Perl was written by a linguist, not an engineer. As such, it's harder to learn (it's got tons more keywords and context), but once you get the hang of it it's much more expressive. The following single line:

    @Lines = sort { $a->{Name} cmp $b->{Name} } @Lines;

    unfolds into several lines of C++, plus a subroutine definition with datatype definitions. The following line:

    @Files = ;

    can be implemented using one of over a dozen possible library calls in C++, but is builtin in perl. You don't have to look up the library call interface specific to your system.

    1. Re:Perl is expressive by Okian+Warrior · · Score: 1

      OK, that last paragraphs should read:

      The following line:

      @Files = <c:/Windows/*.exe>

      can be implemented using one of over a dozen possible library calls in C++, but is builtin in perl. You don't have to look up the library call interface specific to your system.

    2. Re:Perl is expressive by dotgain · · Score: 1

      Languages which are simple to learn (c++, for example)

      WHAT?

  32. Re:Python, please by geminidomino · · Score: 1

    Dafuq?

    You do realize that the creator of Python's name is Guido van Rossum, and it's not a racial slur, right?

  33. Re:I used it. Once. by Anonymous Coward · · Score: 1

    And, in python:
    list = [1, 1, 2, 2, 3, 3, 4, 4, ]
    unique = set(list)

    Which is more readable?

  34. I love perl by Anonymous Coward · · Score: 0

    I only use perl for small projects, utilities, converters, code generators and the like.

    Have lost track of the number of times I've had to open specialized binary files or muck with transforms I hardly even understood only to quickly find exactly what was needed from CPAN archive every time.

    I don't think I could ever trust myself to write a large program using perl or my perl mindset that comes with it but I also know it saves me a lot of time and allows me to automate things hard to imagine being cost effective to automate any other way.

  35. probably orange and reticulated, too by Anonymous Coward · · Score: 0

    only Guidos boast about their python in polite company.

  36. Re:I used it. Once. by somersault · · Score: 1

    practically unmodifiable once written

    Come on, it's not that bad if you split everything up appropriately into well named subroutines and such like.

    --
    which is totally what she said
  37. Long-time perl developer by dskoll · · Score: 1

    I like Perl. My company sells software that's primarily written in Perl. It's readable and maintainable because we follow strict coding guidelines, use proper modularization, and have unit tests that make sure our POD documentation is complete and up-to-date.

    That said, a few things about Perl worry me. I think Perl 6 is a distraction; someone should take it out and shoot it. I predict it will eventually be abandoned the way PHP 6 was.

    Also, while CPAN is awesome, inter-module dependencies are insane. Moose is all well and good, but sometimes you don't *want* 26MB of overhead in your Perl process just to use a fancy OO system. And since more and more CPAN modules are coming to depend on Perl, fewer and fewer of them are available for high-performance systems or where memory is an issue. Sure, you can get a 64GB server pretty cheaply, but (for example) when you're running 150 processes to scan email, 26MB/process adds up pretty fast.

    The worry I have with Perl is that some developers are adding features that are pretty cool in theory and may make OO programming a bit nicer but which impose way too much overhead in many cases and which implement things 99% of people won't need.

    1. Re:Long-time perl developer by kwoff · · Score: 1

      Moose should be a swear word. Every time I've encountered Moose, it just made maintenance harder. The argument about eliminating boilerplate code is laughable, when you look at any Moose class with pages of crap at the top. (should be indented, but slashdot ecode sucks)

      has 'blah' => {
      is => 'rw',
      isa => 'Str',
      };

      Thanks, I could've put that in a hash, and I didn't really care if it was a string or modifiable. Now I get useless Java-like stacktraces to boot. Not to mention the implicit things like "_build", "clear", and reimplementations of things that were already native perl (traits; oh, wow, I can....count the number of items in an array now? and return those items? and tell if it was empty? Thanks for the unnecessary crap, oh yes this is much more readable....).

  38. Re:I used it. Once. by readin · · Score: 4, Insightful

    What I found in using Perl was that no two Perl programmers could read each others code. Much of the expressiveness and versatility that people talk about comes at the expense of a huge amount of syntax and the ability of the language to assume values (like $_ instead of requiring them to be explicit). What happens in practice is people learn a subset of syntax which is large enough to do what they need to do and it often isn't the same subset that someone else learned. And when reading someone else's code, it can be very difficult to look things up because it often isn't even clear what the syntax is (in part because so much gets assumed).

    When the boss hands me a flat text file with 50,000 lines in some random format that needs to be parsed and loaded into the database, I dust off my Perl book and write a short application to read each line and spit out SQL. I don't need the safety of Java or the byte processing of C. I don't need to handle every possible exception that could be thrown when opening a file. I don't need a GUI. I just need to open a file, read a line of text, use some regular expressions, do some tokenizing, and spit out more text into a separate file. Perl is fantastic for that. But I don't find much other use for Perl.

    --
    I often don't like the choices people make, but I like the fact that people make choices. That's why I'm a conservative.
  39. Re:I used it. Once. by CaptSlaq · · Score: 1

    practically unmodifiable once written

    Come on, it's not that bad if you split everything up appropriately into well named subroutines and such like.

    This is one of the most important things anyone approaching perl needs to grok. Perl gives you enough rope to hang yourself, that's why I use it. Lack of awareness of that has bitten me in the backside enough that I've learned this lesson.

  40. Moose -> Mouse -> Moo -> Mo by oneiros27 · · Score: 2

    That's why there's Mouse. And if that's still too large for you, there's Moo. And when even that's still to large, there's Mo

    And you can select which one has the features you need, without the bits you don't care about ... but they've all got basically the same general API, so you can change it up as needed.

    --
    Build it, and they will come^Hplain.
  41. Re:I used it. Once. by CaptSlaq · · Score: 4, Insightful

    And, in python: list = [1, 1, 2, 2, 3, 3, 4, 4, ] unique = set(list)

    Which is more readable?

    use List::MoreUtils qw(uniq);

    my @words = qw(foo bar baz foo zorg baz);
    my @unique_words = uniq @words;

    What was that about readability?

  42. Re:I used it. Once. by bill_mcgonigle · · Score: 3, Insightful

    What I found in using Perl was that no two Perl programmers could read each others code.

    That's silly. I'm just a medium-grade Perl jockey and I read and understand other projects' code. I find bugs and submit patches.

    Perl doesn't force good style on you, but if you follow the guides of Perl Best Practices and check yourslelf with Perl Critic you're going to produce code that most programmers can follow.

    Some people aren't comfortable with 'enough rope to hang yourself', which is fine. Others think that forced indentation is the answer to good code style (I think semantic analysis is better). There are lots of options.

    --
    My God, it's Full of Source!
    OUTSIDE_IP=$(dig +short my.ip @outsideip.net)
  43. Re:I used it. Once. by lennier · · Score: 2

    a good example of why perl is awesome

    The interfacing Linux and MSSQL, the running for five years, or the looking like Greek?

    --
    You are not a brain: http://books.google.com/books?id=2oV61CeDx-YC
  44. Re:Why perl? Because .... by xanthos · · Score: 2

    There is more than one way to do it.

    Perl can pretty much integrate anything with anything. Hardware or Software.

    It is the Duct tape of the interwebs.

    It is a swiss army chainsaw.

    And yes,it can be nearly impossible to decipher what the code is doing, Oh, but the moment of enlightenment you have when you do figure out an obscure but elegant piece of code.

    That, my friend, is "Why Perl?".

    -Xanthos

    --
    Average Intelligence is a Scary Thing
  45. Unicode support? by ThePhilips · · Score: 1

    Great plans are great, but how about decent Unicode/utf-8 support first??

    And by decent I mean a single global flip switch to tell the Perl that the script runs in Unicode/utf-8 only environment, all regexes should be Unicode aware, all file and directory names are Unicode, all text files are Unicode and so on and so forth. Well, you know, a switch to tell Perl interpreter that it runs on a system made in 21st century.

    Otherwise, Perl is a great thing. But the bastard Unicode (and locale) support already makes it way too crippled for modern tasks.

    Well I don't have a crystal ball but I cannot see the language fading from usage in the next quarter century

    One doesn't have to have a crystal ball to see that Perl is slowly fading into irrelevance. Most mobile platforms BTW, just like desktops and servers, are fully Unicode compatible - unlike Perl.

    And heck, 25 years on - and we still do not have standard UI toolkit.

    --
    All hope abandon ye who enter here.
    1. Re:Unicode support? by Anonymous Coward · · Score: 0

      And by decent I mean a single global flip switch to tell the Perl that the script runs in Unicode/utf-8 only environment, all regexes should be Unicode aware, all file and directory names are Unicode, all text files are Unicode and so on and so forth.

      Try "-CADS"; it's been there for years.

    2. Re:Unicode support? by ThePhilips · · Score: 1

      Wow. And I was looking for it for years too - fruitlessly.

      And what would be the magic option to make the regexps Unicode-aware? so that e.g. \w would really match all word characters, and \s all possible spaces, and so on and so forth? The `/u` is pretty useless because one has to add it to all regexps in the program - and occasionally it also behaves illogically depending on other options (`use locale` and similar).

      --
      All hope abandon ye who enter here.
    3. Re:Unicode support? by ThePhilips · · Score: 1

      Nope. `-C` controls only the IO specific options. It doesn't do anything else. It doesn't even tell Perl that the script itself is written in Unicode. All `-C` does is to remove pile of `use`s from the script beginning.

      --
      All hope abandon ye who enter here.
    4. Re:Unicode support? by onefriedrice · · Score: 1

      Great plans are great, but how about decent Unicode/utf-8 support first??

      Perl has exceptional support for Unicode. The accepted answer on this SO question provides a pretty comprehensive list of the challenges that Unicode brings, and why there cannot possibly be a magic "switch." Such a switch would surely break a lot of code, so pre-UTF-8 code that needs to support UTF-8 does need to be updated, but writing modern Perl programs that support Unicode is really easy.

      And heck, 25 years on - and we still do not have standard UI toolkit.

      What would a "standard" UI toolkit buy us? Just pick one of the many available tookits on CPAN and be happy. They're all great.

      --
      This author takes full ownership and responsibility for the unpopular opinions outlined above.
    5. Re:Unicode support? by ThePhilips · · Score: 1

      Great plans are great, but how about decent Unicode/utf-8 support first??

      Perl has exceptional support for Unicode. The accepted answer on this SO question provides a pretty comprehensive list of the challenges that Unicode brings, and why there cannot possibly be a magic "switch."

      I've seen and read all the whining and bickering about why it can't be done. Somehow in the past there were no bickering about hardcoding ASCII support - but now, adding proper Unicode support is suddenly such an impossible task.

      The simple truth is that it is obviously possible - Python does it out of box.

      Such a switch would surely break a lot of code, so pre-UTF-8 code that needs to support UTF-8 does need to be updated, but writing modern Perl programs that support Unicode is really easy.

      Most of the hardware which ran the old scripts has being literally completely retired. There is no point of being 100% compatible to the scripts which are not used anymore. I know it because I have participated in a number of migrations. Effort should have went into making it as simple as possible to update such scripts to support Unicode. I was in the shoes - with rather pathetic results: ASCII still rules Perl. Neither `use locale` nor `use utf8`/`use Unicode` facilitate in the least porting of the old scripts to new *nix systems, all of which are fully utf-8 based.

      Also writing new scripts with Unicode support is still non-trivial and akin to a walking over minefield. That was at least my experience. I've spent at least two full weeks digging through the perlmonk archives to no avail. There are only hard ways: do lots of silly shite all over the scripts OR change the language, because, for example, Python doesn't have the problem at all.

      --
      All hope abandon ye who enter here.
    6. Re:Unicode support? by chromatic · · Score: 1

      Python automatically guesses encodings, automatically normalizes into the proper form, automatically casefolds, and automatically applies the correct collations especially respecting the sources and sinks of data?

      If that were true, I would be quite impressed.

    7. Re:Unicode support? by dskoll · · Score: 1

      Great plans are great, but how about decent Unicode/utf-8 support first??

      Modern Perl 5 has excellent Unicode and UTF-8 support. What about it do you find lacking?

      And heck, 25 years on - and we still do not have standard UI toolkit.

      I don't know of any other scripting language (except Tcl) that does have a standard UI toolkit.

    8. Re:Unicode support? by onefriedrice · · Score: 1

      Also writing new scripts with Unicode support is still non-trivial and akin to a walking over minefield.

      Well, I write Perl code daily, and I personally find it quite easy to write modern Perl applications with UTF-8 support. I don't think I'm particularly brilliant, either, but even I can do it! So... either I need to find out what I'm doing "wrong" to make this such a non-issue for me, or your concerns are a little bit overstated.

      --
      This author takes full ownership and responsibility for the unpopular opinions outlined above.
    9. Re:Unicode support? by ThePhilips · · Score: 1

      Python automatically guesses encodings, automatically normalizes into the proper form, automatically casefolds, and automatically applies the correct collations especially respecting the sources and sinks of data?

      Yes, it actually can guess encodings(*). But also it simply has sane default for the text files: utf-8 (and allows explicit encoding specification). Strings are always Unicode (even if only ASCII is stored there). Python also validly assumes that the source code is also Unicode. Casafolding, collations - have no idea what they are, but in my experience "it just works." One doesn't need to do any additional hand-waving to open input text, open output text file and run code/regexps/etc on it, all properly Unicode aware out of box.

      (*) AFAIK it properly reacts to the BOM in the beginning of the files.

      That is also aggravated in Perl because (unlike in Python) there are no string manipulation functions - there are only regexps. And regexps in Perl (unlike in Python) by default are not Unicode-aware.

      You can't imagine how nice it is to have the \w to match ALL word characters - without reading tons of silly bickering and escapism of why it can't be done easily in Perl or what dozens of gotchas I have to be aware of.

      Just think of it: a fully Unicode aware shell filter in Python is shorter than in Perl. And we are still talking about future of the Perl??

      --
      All hope abandon ye who enter here.
    10. Re:Unicode support? by ThePhilips · · Score: 1

      Great plans are great, but how about decent Unicode/utf-8 support first??

      Modern Perl 5 has excellent Unicode and UTF-8 support. What about it do you find lacking?

      The fact that other languages, built to modern standards, do it much better. E.g. Python.

      Also, by Perl's own standards Unicode support in Perl sucks: one has to jump through many hops before it works as expected. While in other modern languages it is out-of-box.

      And heck, 25 years on - and we still do not have standard UI toolkit.

      I don't know of any other scripting language (except Tcl) that does have a standard UI toolkit.

      And that's the reason why it shouldn't be done?

      Ironically, Tcl still persists in many niches, in part thanks to the Tk. Seasoned pros can build a useful - and portable - GUI in matter of minutes.

      --
      All hope abandon ye who enter here.
    11. Re:Unicode support? by chromatic · · Score: 1

      Not all of the world is UTF-8. Assuming that it is is, in fact, wrong.

      I appreciate your confidence that things you've never heard of before must exist and work properly, but I'll take that with a grain of salt. Unicode isn't merely UTF-8 and BOMs and hand-waving. Unicode is a set of properties and rules about how to use those properties correctly. If you don't know what they are and when to use them, no language can use them automatically for you on this side of the strong-AI singularity.

      (It's easy for me to imagine reading from a filesystem that doesn't return data encoded in UTF-8, or data from the network which doesn't supply a correct encoding or any encoding, because that happens all the time. You can expect that everything always does exactly what you expect, or you can write correct and robust code. You cannot do both.)

    12. Re:Unicode support? by dskoll · · Score: 1

      The fact that other languages, built to modern standards, do it much better. E.g. Python.

      Please enlighten me. What, specifically, is lacking in Perl's Unicode support? And how could it be improved? I've found it to be excellent, though the perlunicode man page must be read very carefully.

      Ironically, Tcl still persists in many niches, in part thanks to the Tk.

      I love Tcl/Tk. And guess what? Perl can use Tk as well, so there's your standard toolkit. I believe Python can also use Tk.

  46. Testing by Tenebrousedge · · Score: 1

    I ask this question in ignorance: what does the much-vaunted CPAN contain within it that has unit tests?

    It is my current belief that any code lacking some sort of proof of correctness is valueless. In many cases it is worse than having no code at all.

    I have strong feelings concerning the promotion of untested or untestable code, but will reserve them until I know whether they're warranted.

    --
    Those who advocate genocide deserve every protection afforded by law, and none afforded by common human decency.
    1. Re:Testing by chromatic · · Score: 2

      ... what does the much-vaunted CPAN contain within it that has unit tests?

      Any serious distribution on the CPAN has at least a decent test suite in its t/ directory. Everything uploaded to the CPAN gets run through the CPAN Testers service, often within minutes of the upload.

      search.cpan.org has over 3200 results for module names which contain the word "Test".

    2. Re:Testing by Anonymous Coward · · Score: 1

      Nearly every Perl module on CPAN contains a test suite. It is the 't' folder in the CPAN distribution, and it is run automatically when you tell CPAN to install a module. Some test suites are of course better than others...

      Here is a list of the modules with tests:
      http://cpants.charsbar.org/dist/complying?metric=has_tests

      Less than 5% of the modules don't have tests:
      http://cpants.charsbar.org/dist/shortcoming?metric=has_tests

      And I would guess that most of those are either throw away projects or meta packages that join up other modules that do have tests.

      Testing is taken seriously by the Perl community.

    3. Re:Testing by Anonymous Coward · · Score: 0

      It is customary for all CPAN distributions (aka modules) to include a full test suite. The tests are executed every time the distribution is installed. If any errors show up, the installation fails. This ensures that whatever you install, it will work in your script as expected. However, neither Perl nor CPAN enforce testing, and such tests are no proof of correctness.

      While it is possible to write utterly untestable code, I wouldn't want to show such code to the world.

    4. Re:Testing by phantomfive · · Score: 1

      If you read the article, it discusses in detail the Perl community's efforts on testing and verification.

      --
      "First they came for the slanderers and i said nothing."
  47. Re:I used it. Once. by geekoid · · Score: 0

    Whats more readable french or German? Depends on which one you know.
    "foo bar baz foo zorg baz"
    how about you use good names instead of intentional vague ones to make some kind if ill advised point.

    --
    The Kruger Dunning explains most post on /. http://en.wikipedia.org/wiki/Dunning%E2%80%93Kruger_effect
  48. Perl versis c++ by Okian+Warrior · · Score: 3

    Languages which are simple to learn (c++, for example)

    WHAT?

    Ahem. "Languages which are simple to learn (c++, for example)".

    Perl has lots more reserved words than c++.
            (Examples: "say", "not", "and", "open")

    Perl has lots more operators than c++
            (Example: "//" is an operator in perl. So is "<=>", "+/*", "..", and "eq").
            (See if you can understand the flip flop operator on first reading.)

    Perl has several contexts, and the meaning of an operator or function is context dependent.
            (Example contexts: "scalar", "list", "null", "string")
            (Example differences: Saying "$i = sort @array" has a completely different meaning from "@i = sort @array")

    Perl distinguishes a variable from its value.
            (Example: $i = 12; followed by $i = "twelve". The same variable, points to one of two values in memory. C++ binds the variable to the memory location, perl does not. Programmers have trouble wrapping their mind around this.)

    Perl references are not pointers (but have some similarities). C++ programmers have a hard time with this also.

    Perl has all the overloading and class syntax found in c++.

    Perl doesn't have a precompiler.

    1. Re:Perl versis c++ by dotgain · · Score: 1
      Certainly, what you say is true. Your response is well reasoned, and I appreciate that. I never said Perl itself was easy to learn, and I've only got one nitpick:

      C++, by its use of namespaces, avoids things like std::vector, std::string etc. being 'reserved words', but that doesn't change the fact that they're there to learn. Yes, Perl has a large number or reserved words compared to C et. al. but I've never felt that these are what makes Perl hard to learn.

      When I began learning C++ I initially felt it was easy to learn - only because I didn't realise how much of it I had yet to face. In reality it's actually a long road to becoming a good C++ programmer - equally true of Perl. I think my biggest disadvantage was learning C and becoming quite proficient in it long before I learned C++. I never did find a C++ book that starts out with "Okay, so you already know C, here are all the C things you need to forget about"

      I don't mean to criticise C++ at all (you won't have any trouble finding people who've gone to great lengths to do so) but I maintain that learning it well is not "easy" by any means.

  49. Re:Python, please by maxwell+demon · · Score: 1

    What's racist about that comment?

    --
    The Tao of math: The numbers you can count are not the real numbers.
  50. Re:Moose - Mouse - Moo - Mo by dskoll · · Score: 2

    And you can select which one has the features you need, without the bits you don't care about

    In theory, yes. In practice, no, because sometimes a CPAN module will insist on one specific module. And woe betide you if you want to mix modules that use different OO bases.

    The mere existence of Moose, Mouse, Moo and Mo that purport to solve the same problem is an indication of a deeper underlying problem.

  51. Re:Python, please by FacePlant · · Score: 1

    Guido is the guy with the car.
    Where I grew up, most of the Guidos were Irish kids anyway.

    --
    My Heart Is A Flower
  52. Re:I used it. Once. by Anonymous Coward · · Score: 0

    What I found in using Perl was that no two Perl programmers could read each others code. Much of the expressiveness and versatility that people talk about comes at the expense of a huge amount of syntax and the ability of the language to assume values (like $_ instead of requiring them to be explicit).

    Hence the reason I always use explicit variable naming regardless of the programming language. On one project I inherited Perl code written every Perl idiom under the sun (the previous person was a Sun consultant). Not only was the code incapable of achieving the business requirements, it was terribly coded to the point that I started from scratch, gathered all the necessary business requirements for the entire lifecycle of the data, and reimplemented the entire system. The task took less than 3 months to complete and was so well documented, internally and externally, that I asked a co-worker to perform the final pre-production deployment QA assessment. Perl is capable of great things in the hands of a competent software developer / programmer.

  53. Re:Moose - Mouse - Moo - Mo by Anonymous Coward · · Score: 1

    You must not be aware that Moo and Moose play very nicely together. When Moose starts Moo classes are inflated and become full Moose participants. Many CPAN modules are migrating to Moo explicitly to support both. Now you can have your cake and eat it too.

  54. Re:I used it. Once. by Anonymous Coward · · Score: 0

    Honestly, how can you not give that one to Python. I understand what a "set" might mean, so it's two lines make sense even if I know nothing about that language. It makes a list of a bunch of redundant stuff, makes a "set" out of it and you're done. So clearly Python natively supports lists and sets.

    The Perl has got these "@" signs and "my" floating about for no obvious reason, never mind that "use" followed by gibberish that I would never have guessed. I mean, you make anything look simple by implementing it somewhere else and then just "use" it.

    All languages have their strengths and weaknesses, but seriously, trying to claim "readability" for Perl? C'mon.

  55. Re:I used it. Once. by durdur · · Score: 1

    I've used it more than once, but not often enough that I don't have to go back and learn parts of over the next time I use it.

    It just isn't very intuitive. The regex support can do awesome things, but just I can't seem to keep enough of it in my head to be productive. Or if I do, it leaks out when I'm off coding in some other language :-).

  56. Slashdot uses Perl. by Jane+Q.+Public · · Score: 1

    Slashdot is programmed in Perl. I would not consider that to be a recommendation.

    1. Re:Slashdot uses Perl. by multicoregeneral · · Score: 1

      And that is why it's doomed. DOOMED I say!

      --
      This signature intentionally left blank.
  57. Re:Python, please by approachingZero+ · · Score: 1

    I don't know why but I like your sense of humor. Rock on.

    --
    'I don't know what it's called. I just know the sound it makes, when it takes a man's life.' ~ Four Leaf Tayback
  58. Re:I used it. Once. by hermitdev · · Score: 2

    The Python is still more readable. First, you had to import an extra library (which, ok, python is built upon libraries). But, what the FUCK does "qw" mean? One can guess, and only guess, for the context that it's some sort of means to delineate a list. my @whatthefuck = ....; considering that on a lot of perl you're going to see: my $whatthefuck = ...; and that the @ and $ variables are two different things... And, you may hear the argument that "those are namespaces". bullshit. they're not namespaces. C++, Java, C# & Python have namespaces. @/$ does not denote a namespace. Especially, given appropriate context, you can use one of the other to change how the variable is treated. That's a cast, not a namespace. Fact is, Perl is W.O.R.N. language: Write Once Read Never

  59. Re:I used it. Once. by budgenator · · Score: 1

    You can write some pretty obtuse Perl, but that's mainly a style thing with the programmer, just using English.pm helps a lot.

    --
    Apocalypse Cancelled, Sorry, No Ticket Refunds
  60. Re:I used it. Once. by budgenator · · Score: 1

    use List::MoreUtils qw(uniq);

    But, what the FUCK does "qw" mean? One can guess, and only guess, for the context that it's some sort of means to delineate a list.
    Fact is, Perl is W.O.R.N. language: Write Once Read Never

    qw() is the quote word function it purpose is to keep you from wearing out your ['] key;
    example
      my @names = qw(Kernighan Ritchie Pike);
    is the same as
    my @names = ('Kernighan', 'Ritchie', 'Pike');.

    --
    Apocalypse Cancelled, Sorry, No Ticket Refunds
  61. I tried it for a while but... by Anonymous Coward · · Score: 0

    ... then I asked myself: Why do I have to learn lots of subtle rules about "bare words", implicit $_, functions clobbering implicit things such as $_ or iterators, dynamic scope, disambiguation with a plus sign or a semicolon at the beginning of the block, "indirect object" notation, how file handles work, and how list and scalar context work, when virtually every other language has found simple and direct rules to almost all theses things and they let me move forward faster during the learning process?

    C'mon, a programming language is supposed to be _designed_, it is supposed to be logical and simple enough so that a programmer can "run the interpreter in his head" in order to understand and debug things. It should _not_ use "heuristics" (as Perl docs and books say) to parse things. It should _not_ look like a spoken language that evolved haphazardly during hundreds of years. It should be flexible, but if it has sharp edges, it should have a good handle too!

  62. since 1.0 by whistl · · Score: 1

    Like many of you, I've been learning and using Perl since 1.0 was first released on CSU. I was privileged to be able to contribute to the early versions by porting Perl to the many various platforms I had access to at my employer (a compiler company) at the time. 25 years later, I still find Perl useful in my current job. Love it. Thanks Larry and everyone else!

  63. Predicative if and unless by ultrasawblade · · Score: 1

    Really like how in Perl I can do "{blah blah} if (condition)", and Perl's the only language I know of that has an "unless" keyword. I know it's basically an "if" with it's condition negated, but I still like it.

  64. Re:I used it. Once. by jones_supa · · Score: 1

    Sounds like Perl. Powerful, accessible to a complete beginner, reliable, and practically unmodifiable once written.

    That brought up an interesting question in my mind. Could it be possible to grab some GPL-licensed OSS project, make modifications to it, run the source code through some insane obfuscator, and then still be legally able to redistribute it?

  65. The language that began my career by bgibby9 · · Score: 1

    Happy Birthday Perl... you're the gateway that got me into programming in the first place and I always relish the opportunities I get to work with ya :)

    --
    http://www.gibby.net.au
  66. Happy Birthday Perl: Some Personal Thoughts by hughbar · · Score: 1

    Happy Birthday Perl. I'm 62 and have been using it as my main language since about 1995.

    Actually, because it's linguistics based, rather than elegant computer science, DWIM [do what I mean] and TIMTOWTDI [there's more than one way to do it] it always feels very natural.

    Also, although I agree its confusing sometimes [lots of sigils, autovivification zombie horror etc.] it's also very very expressive. Try COBOL, try Java and try APL if you want highly expressive but incomprehensible minimalism [and find a new keyboard].

    Finally, as at least one poster has already said, CPAN gives nearly any project in Perl a running/sprinting start.

    --
    On y va, qui mal y pense!
  67. Reading each other's code? by Giftmacher · · Score: 2

    Lots of comments about being unable to read code authored by someone else (as usual), but who are these "professional perl coders"? I'd say I'm an intermediate perl programmer, and I've had no trouble reading my old code or anyone else's provided it's been written sensibly. Hell I've even been able to decipher some pretty Byzantine code when required.

    Perl isn't a language without faults, for example OO is not fun in perl. However, it mystifies me to see perl criticised for readability when the coder is, in no small part, responsible for making something decipherable. I've seen shocking code in several languages, where I work I know there's a particularly hairy example of cold fusion we're still struggling to tame... Diabolical use of in-line HTML, thousands of lines of code without so much as an attempt at basic formatting (no indents) etc, etc. It was written by a genius I'm told, but why they deserve that title when they weren't smart enough to write something we could maintain I'll never know.

  68. You mean like your bullshit test on hosts files? by Anonymous Coward · · Score: 0

    See subject-line: I shot so many holes into your b.s. "test", it's not funny. To wit:

    Tenebrousedge's "test method" is FLAWED -> http://tech.slashdot.org/comments.pl?sid=3239985&cid=41943501

    How so?

    ---

    1.) He used a LOCAL DNS SERVER most folks don't have these setup, as they waste CPU cycles, RAM, & other forms of I/O PLUS electricity as a result of those things, and more complexity - for doing what a custom hosts file can from a single file only, that's "tightly integrated" into the OS & IP stack!

    (There is NO WAY a REMOTE DNS SERVER returns results in only 3ms when it hits NXDOMAIN queries unless it's local... no way, as they typically return results for host-domain name resolution to IP addresses in 30-100's of ms...) - NOR DID HE FLUSH THE LOCAL DNS CACHE!

    ---

    2.) He used a LARGER custom hosts file set of "favorites" - mine has 20 @ the TOP of my custom hosts file (important) - NOT 34 entries/records in the hosts file (almost double)...

    a.) That is THE only thing I care that gets speed out of MY custom hosts file - the rest are BLOCKED & I could care less HOW FAST they are gotten to - I never intended to get to them since they're blocked out, in the 1st place!

    b.) I place my favorites @ the TOP OF MY HOSTS FILE, which even beats DNS server indexing up to around 2++ million records or so...

    ---

    3.) He queried a local browser cache AND had the local DNS cache active, non-flushed first! This makes DNS results he posted again, much faster, but not honest regarding remote DNS servers.

    a.) NEITHER AdBlock nor FF are able to obtain hosts-domain names resolutions, by themselves as he said, to IP addresses BEFORE the IP stack gets it for it, FIRST - that comes WAY before that... (more on that below, in detail).

    b.) The IP stack is written in C & Assembly with over 40++ yrs. of optimization put into it, running in ring 0/rpl 0/kernelmode

    c.) That is FAR faster than usermode browsers OR THEIR ADDONS are which slow up more with addons (firefox proves that much easily, load it up with addons & see)

    d.) HOSTS act merely as a FILTER for the IP stack, & hosts are the FIRST THING YOUR SYSTEM QUERIES (then dns clientside caches, then remote DNS)) for host-domain name resolution to IP addresses...

    ---

    4.) Nor did tenebrousedge account for time taken by AdBlock itself, parsing for WHAT to block out - this is NOT some "absolutely free operation", nothing is...

    ---

    5.)

    "Requests that are not generated by the browser are faster than ones that are and resolve locally in the hosts file." - by Tenebrousedge (1226584) on Thursday November 08, @06:20PM (#41925925)

    Why on EARTH would the browser make requests to things that the Operating System & IP stack ALREADY KNOW ARE BLOCKED via the custom hosts file filter for? The IP stack, via the hosts file, has ALREADY determined that anything BLOCKED is blocked before the browser EVER HAS TO MAKE A DETERMINATION OF WHAT IT IS IT IS LOADING!

    In fact, because of that fact?

    Custom hosts file blocking makes AdBlock REDUNDANT & actually wasteful since what is blocked was blocked FAR BEFORE BROWSERS ARE INVOLVED IN THE PROCESS EQUATION, based on the entries in line item records the custom hosts file has in it...

    It's the same principle advantage custom hosts files have over remote DNS servers:

    I.E. -> You NEVER HAD TO CALL OUT TO THEM (NOT for favorites you 'hardcoded' into the custom hosts file, OR, NOT for blocked out known malicious sites)...

    Plus locally resolving host-domain names to IP addresses is going to occur MUCH faster out of a custom hosts file, off mechanical HDD's even (7ms access on a 10k rpm one her

  69. Re:I used it. Once. by Anonymous Coward · · Score: 0

    Most of my Perl scripts have no comments, since they're primarily for my own use, and I have no problems reading code I wrote 5 years or more ago. Unmaintainable code can be written in any language. To me Perl is the most elegant, expressive language. Maybe those who find Perl so unmaintainable or unreadable never bothered to learn the language properly in the first place.

  70. Re:I used it. Once. by Anonymous Coward · · Score: 0

    Clearly the Python version, because it doesn't has strange array name operators and pseudofunctions like qw.

  71. Re:I used it. Once. by nmr_andrew · · Score: 1

    This is one of the most important things anyone approaching any programming or scripting language need to grok, at least if you want anyone (including yourself) to be able to figure out what your code does several years down the line.

  72. Re:I used it. Once. by nmr_andrew · · Score: 1

    Thanks, I just learned something useful on /.

  73. PHP by Anonymous Coward · · Score: 0

    What's hilariously funny is that most of these huge sites like Amazon and Facebook have moved to the language that all you "uber" geeks pontificate about to the language you all "love to hate"... yes, get ready... PHP.

  74. Re:I used it. Once. by Anonymous Coward · · Score: 0

    You criticism of Perl is pretty common. (No two programmers can understand each other's code, code looks like gibberish, etc).

    However, there is a serious fault in your reasoning. For some reason, you and many others judge Perl by the code of programmers who have not learned Perl well. Heck a lot of people learned their Perl from "Learn Perl in 24 hours" type of book or online tutorial. Such "programmers" generally do not have to share their code to begin with. Most just use it for one-off throwaway scripts. Getting started coding in Perl and producing useful code is deceptively simple. However, Perl is much deeper than say AWK, which can indeed be learned in an evening.

    I would say, find code written by someone who has at least read "Programming Perl", the main reference book on Perl, or the complete set of Perl man pages, which are excellent and are much better than the bundled documentation of many other languages. The use of $_ and common Perl idioms will become pretty clear and intuitive after reading a good reference. If you want to see good code, or learn how to write good Perl code, there is no substitute for reading good Perl code. Take a look at the code of the standard Perl modules as well as most CPAN Perl modules and then still try to decide if no two Perl programmers can understand each others code.

  75. Re:You mean like your bullshit test on hosts files by Tenebrousedge · · Score: 1

    Hi, APK. How's the life?

    I have been working pretty hard on other projects; I haven't had time to set up my new computer let alone the tests we discussed. Really, it's quite depressing.

    Your insistence that "the IP stack had to do some work first" is a complete departure from reality. A browser request starts in the browser, and may not even reach the DNS layer -- for instance, if you're requesting a local file (file://), your browser is not going to do a DNS request.

    If you're the kind of guy who is going to completely ignore the factual when it suits him, then I'm probably not going to make these benchmark numbers a real priority.

    And honestly, if you keep trolling my posts on here, writing a plugin to automatically hide your posts would be at least as much fun to write as doing these benchmarks would be. The next step would be to run a script to automatically post links to said plugin after every post of yours. So let's keep the drama to a minimum, shall we?

    --
    Those who advocate genocide deserve every protection afforded by law, and none afforded by common human decency.
  76. Read docs from MS: You fail... apk by Anonymous Coward · · Score: 0

    BROWSERS CAN'T DO A THING UNTIL THE HOSTNAME QUERIED IS RESOLVED TO AN IP ADDRESS, FIRST!

    E.G.-> How would a MERE BROWSER know where to go, by itself, first (as to an IP address from a hostname/domainname), hmmm?

    Man, lol... You don't "get it", OR HOW IT REALLY WORKS, do you? READ THIS:

    ---

    Microsoft TCP/IP Host Name Resolution Order:

    "Host name resolution generally uses the following sequence:

    The client checks to see if the name queried is its own.

    The client then searches a local Hosts file, a list of IP address and names stored on the local computer.

    Domain Name System (DNS) servers are queried.

    If the name is still not resolved, NetBIOS name resolution sequence is used as a backup. This order can be changed by configuring the NetBIOS node type of the client."

    ---

    The 1st thing a system looks @ is the hosts file for host-domain name resolution to IP address!

    ---

    That also makes using AdBlock redundant for adblocking when you use a custom hosts file, by the way (not that anyone with any GOOD SENSE would use it now, since by default it DOESN'T BLOCK ALL ADS)

    In hosts files, a good one has all known adservers blocked out & that grows here, constantly, from 12 reputable & reliable sources.

    APK

    P.S.=> Your "test hosts file" also was bogus... how so?

    It used DOUBLE the entries mine has for the top 20 entries with 34 in yours, that's b.s. testing as well!

    Why?

    FIRST OF ALL:

    They're my fav sites & only ones I care to get to (rest in my hosts files are below that & blocked out known bad sites, adbanners servers, etc. that I never INTEND to EVER reach), & that many place the way they are @ the top of the file even beats DNS indexing up to 2++ million entries for seek/access/read & they're read FIRST from the top of the file.

    SECONDLY:

    What did you do? WELL - you used 34 entries, nearly DOUBLE the size of mine & that is a b.s. test, because that means you had to "fake it" basically to produce the results you did, by doing twice as many reads for remote DNS resolutions to come back to you in the same speed as a custom hosts file read!

    (Faster on mine here since 0ms seek/access off my Gigabyte IRAM SSD (since I relocate my registry path to hosts onto it), & since it's also cached into RAM by the local kernelmode disk subsystem)...

    ... apk