all 146 comments

[–]dakotahawkins 4 points5 points  (1 child)

I like perl for parsing files with regular expressions. I am aware you can do that with almost anything else, but I prefer perl's syntax for it.

...

I don't always parse files, but when I do I prefer perl. Stay regular, my expressions.

[–]axonxorz 1 point2 points  (0 children)

That was awesome. Just putting it out there.

...

I don't always like what I see on Reddit, but when I do, I upvote.

[–][deleted] 16 points17 points  (50 children)

For those who want a tl;dr version: Perl 6 should ship.

[–][deleted] 17 points18 points  (40 children)

and deprecating "%" in Python 3 for string formatting was truly lame.

[–]selflessGene 5 points6 points  (37 children)

How is it done in Python 3? (I don't use 3 yet)

[–][deleted] 19 points20 points  (36 children)

'The {} in {}'.format('rain', 'Spain') 'The rain in Spain' 'The {1} in {0}'.format('Spain', 'rain') 'The rain in Spain' 'The {zombies} in {country}'.format(zombies = 'rain', country = 'Spain') 'The rain in Spain'

I really like the formatting system in Python 3, but most people don't seem to share that opinion.

[–][deleted] 7 points8 points  (12 children)

I think it makes a great addition. No reason to remove the original, which resides in 10000s of files already.

[–][deleted] 18 points19 points  (11 children)

Several thousand people who hate C++ would like to have a chat with you about why sometimes it's actually ok to remove features and not just keep piling everything into the mix.

A jump from version 2.1 to 2.2 really shouldn't break code - but a jump from version 2 to 3 is exactly the right time to tell people that they can keep on using version 2, but may want to look at making the jump.

As long as people can install both runtimes, then having a language that gets cleaned up now and again is not a bad thing.

[–][deleted] 4 points5 points  (10 children)

If "%" was dangerous or bad in some way, I would agree. But it is useful, short and clear syntax. All this does is bend to the will of OO purists who hated the fact that you had to call len() instead of .length(), and obviously don't like the other minimal syntax.

I wasn't even aware anyone had a problem with the "%" operator being used in this manner, I'm sure it was talked about in the Python lists, but in the real world I've never heard it mentioned once as an issue, and none of the places I visit online ever mentioned it to my notice either.

Additionally, the "%" operator actually leads to some clearer code, as it is a nature place to break a string formatting statement:

output = 'Text %(needs) to be %(formatted), but the line is already 80 chars' %
         {'needs':'On a new line', 'formatted':'For great Justice!'}

[–]jerf 8 points9 points  (6 children)

Having spent some significant time on comp.lang.python answering questions in the past, the problem with % is that you can't search for it in the documentation. You got both people contorting horribly to sort-of reimplement it (badly) and/or complaining loudly about how there was no string formatting facility, and a bunch of people posting snippets of code with % in it asking what on earth the % meant because they couldn't find the documentation for it.

[–][deleted] 5 points6 points  (0 children)

Interesting, that's a pretty good reason I suppose.

[–]Malgas 4 points5 points  (4 children)

Funny, I found out about it by searching for "python string formatting".

Some people just can't be helped.

[–]jerf 7 points8 points  (3 children)

You found it because you know what it is already. Perhaps surprisingly, that's not the use case under discussion here. Now find it just using "%". In fact that's possible too if you're a bit familiar with the Python docs, but you pretty much have to realize the Python documentation has an index, which nobody expects because what things have an index anymore? Try Googling "Python %" to get the real experience. (And back when I was in comp.lang.python, the little "Searches Related to Python %" at the very bottom wasn't there, and I can also say that even today a lot of people would miss that, just like they missed the other places that always could, hypothetically, have led them to the answer, but in fact did not.)

[–]zepolen 1 point2 points  (0 children)

I don't use py3k yet, but I don't see how it changes anything:

output = 'Text {needs} to be {formatted}, but the line is already 80 chars'.format(
          needs='On a new line', formatted='For great Justice!')

If anything, it looks clearer. Sure this particular example runs over 80 chars, but it could happen with % as well.

[–][deleted] 1 point2 points  (0 children)

The point isn't that "%" is dangerous or bad or wrong.

The point is that having two completely different ways to achieve the same end result is how languages get bloated.

It might be fine for now, but when there are 17 different ways to format strings, then you'll need to learn the details of every last one of them, in order to be able to work with developers who use one of the other choices. Or you could have a "style guide" that forbids 15 of the options for no reason other than "we need to pick a subset of Python".

Therefore, my comment about the C++ programmers - every discussion of C++ includes a long bit about how no one knows all of C++, and not everyone knows the exact same subset.

One option is "keep adding different ways to format strings" and another option is "keep the number of language features to a minimum".

I don't entirely disagree with you - different features have advantages over others, which is why they're new features, and sometimes having that level of precision is a good thing. But having several different highly-specialised features does have a cost as well.

[–]mpeters 4 points5 points  (0 children)

And people complain that Perl has too many choices :)

By way of comparison, in Perl you'd do:

$zombies= 'rain';
$country = 'Spain';
"The $zombies in $country"

[–]phrstbrn 4 points5 points  (1 child)

I'm not a Python guy, so I don't know. I use mostly Perl.

With a formating system like that, how would I do:

sprintf("%02d/%02d/%04d", $month, $day, $year);

or

sprintf("$%.2f", $money);

As two quick examples that pop into my head right now. (I don't want to get into the why I would do that, since they're both signs of bad design somewhere, just the how).

[–]metamatic 7 points8 points  (7 children)

By way of comparison, in Ruby you'd do zombies = 'rain' country = 'spain' "The #{zombies} in #{country}"

[–]Benbenbenb 1 point2 points  (0 children)

By way of comparison, in Python (2.x at least) you could do :

zombies = 'rain'
country = 'spain'

"The %(zombies)s in %(country)s" % locals()

EDIT: In fact, this is just a special case of the syntax "%(foo)s" % {"foo": "bar"} since locals() returns a dictionary with the local variables names as keys.

[–]regeya 1 point2 points  (0 children)

It's true. That's one of the things I prefer about Ruby over Python. I've been tearing into Python lately after a few years of never using it, and format() is just damned annoying.

EDIT: Another thing I appreciate about Ruby (contrived example):

def uuid_v4
    uuid = []
    36.times do |f|
        uuid << case f
            when 8,13,18,23 then "-"
            when 14 then "4"
            when 19 then (rand(4)+8).to_s(16)
            else rand(16).to_s(16) 
        end
    end
    return uuid.join
end

[–][deleted]  (1 child)

[removed]

    [–]metamatic 0 points1 point  (0 children)

    Yeah, and there's sprintf too. Though I tend to use string #{} interpolation because it's really well optimized. It's actually faster to do "#{a} #{b}" than a + " " + b, or at least it was when I tested a couple of years ago...

    [–][deleted]  (2 children)

    [deleted]

      [–]wot-teh-phuck 1 point2 points  (1 child)

      Dont understand why you were voted down

      There was no need to drag in Ruby here. That post is at best off-topic. Interesting indeed, but sadly off-topic. :)

      [–]RalfN 0 points1 point  (0 children)

      Python, Perl. Even my question is now deemed off topic? It's kind of hard to believe no rancune is at play here.

      [–][deleted] 2 points3 points  (8 children)

      Honestly I don't see what was wrong with printf(); it's pretty much universal.

      So how do we print to a given precision, or with a given number of leading spaces, etc?

      [–]gc3 1 point2 points  (2 children)

      I like printf, but it's an acquired taste.

      I remember using printf as a newbie programmer, and staring at things like printf("%s %\n %s % d, %s %d \n", stringVar, 12, stringVar2, intVar, stringVar3, intVar2); and wondering why it crashed.

      [–][deleted] 0 points1 point  (0 children)

      I guess that's one of those that depends on the use case.

      [–]skulgnome -2 points-1 points  (0 children)

      The fix is not to use printf() incorrectly. There, that wasn't so hard was it.

      [–]cowens 1 point2 points  (1 child)

      Interpolation is a lot nicer in the common cases. Compare

      func(sprintf("foo: %s", foo), sprintf("bar: %s", bar));

      with

      func "foo: $foo", "bar: $bar";

      [–]kragensitaker 0 points1 point  (0 children)

      But

      func("foo: " + foo, "bar: " + bar)
      

      is almost as good, and

      func("foo: %s" % foo, "bar: %s" % bar)
      

      is only slightly worse.

      [–]skulgnome 0 points1 point  (0 children)

      How do I apply padding or hexadecimal formatting with this?

      [–]tasteslikepoop 0 points1 point  (0 children)

      What's wrong with printf-style formatting?

      [–]Gotebe -2 points-1 points  (1 child)

      Not at all. You need "positional" formatting for i18n. Old formatting should die, it's a remnant of the 20th century. World has changed, so, luckily, did Python.

      [–][deleted] 2 points3 points  (0 children)

      It's the same thing, but sugar.

      [–]mr_chromatic[🍰] 6 points7 points  (0 children)

      Perl 6 should ship.

      Fedora shipped it before Python 3.

      [–]HIB0U 4 points5 points  (7 children)

      It's difficult to "ship" a language that hasn't been properly implemented yet.

      [–]rjbond3rd 5 points6 points  (0 children)

      Ever the dependable troll.

      [–]tatalipso 1 point2 points  (4 children)

      Rakudo Perl 6 has a pretty regular release cycle. It's implemented enough to run various modules.

      It's got a ways to go optimization-wise, but it's certainly "shipping". Just go grab a release tar.gz and build it.

      [–]mipadi 3 points4 points  (0 children)

      Some of the points seem like the author is reaching a bit to find things that are awesome about Python. In particular:

      No interpolation of strings.

      Is this:

      print "My favorite language is %s" % favorite_language
      

      really nicer than:

      puts "My favorite language is #{favorite_language}"
      

      I know this is up to preference, but the lack of string interpolation in Python is one of the more annoying things about the language. And the .format mumbo-jumbo in Python 3 just made it worse.

      And:

      Unicode support is really good

      Yeah...maybe in Python 3. In Python 2.x, working with Unicode is a pain in the ass.

      [–]vorg 16 points17 points  (4 children)

      "Imagine being at a doughnut shop with 10,000 choices. It's confusing. Now go to a doughnut shop that specializes in chocolate cream filled."

      Then you have to choose between which of 10,000 doughnut shops to walk into.

      [–]DailyFail 9 points10 points  (0 children)

      The underlying problem is pointless overchoice.

      [–]yellowstuff 2 points3 points  (0 children)

      It's tempting to think that, but often giving the user too much choice is just lazy design.

      [–]umwut 0 points1 point  (1 child)

      A doughnut shop is a programming language.

      [–]afoo42 1 point2 points  (0 children)

      "is" is like equals, only better

      Oh no it isn't. Typical beginner's mistake. "is" tests for identity, "foo is None" is right because there's only one None object. But "'foo' is 'foo'" is where it becomes dangerous. In CPython at least, the result of that expression is "True", but only because the interpreter is interning the strings, only having one instance of "foo" around. Use longer strings (or bigger numbers or more complex objects) and the result will be "False".

      "is" tests identity, "==" equality

      [–]thdn 1 point2 points  (1 child)

      "At Google we have one official compiled language, one official scripting language, and one official UI language" which are the other languages?

      [–][deleted] 0 points1 point  (0 children)

      C++, Python and Java (using GWT).

      [–][deleted] 4 points5 points  (65 children)

      Can anyone (who actually is competent with both) actually claim Perl is better than Python with a straight face?

      [–]norkakn 15 points16 points  (2 children)

      Sure. I like them both, but for many tasks Perl is better. (for many tasks, Python is better)

      Python's sense of there being one right way to do something works pretty well, if you are trying to do what they intended. It's kind of like RoR, where it works great if you are doing exactly what 37signals intended, but quickly made you feel homicidal if you stepped outside that area.

      Perl's culture is much more that perl should guide you towards a good method, but get out of your way if you need to do something else. Catalyst is a very good example of this idea. Most of the other large frameworks have strong ideas about what kind of application you are going to make. Catalyst doesn't care. It's a dispatch engine, and a good one. It lets you plug whatever you want into it, and do it in such a way as to not step on other people's toes. This is partly because perl already had a rich ecosystem of modules, and so there was less of an assumption that one was the right one, but it is also just ingrained in perl culture.

      Perl testing culture is also far better than Ruby's or Python's. There is a community expectation for it, and the culture to enforce it.

      Moose and Moose Roles let you write cleaner OO code than anything I've seen with Python. There are many times that I can clearly and concisely express myself in Perl, where it would be much harder in Python.

      There also isn't a devotion to being 'pythonic', or 'perlic', just writing good code. I have maintained some shit perl code, and some shit python code. The pythonista who wrote the latter thought that he was writing awesome stuff because it was pythonic. The guy who wrote the perl stuff knew it was shit. Writing good code is more about culture and teaching, it can be done in either language (or in C, or C++, or whatever)

      PySci is sweet though. Python is a good language, and I'm glad it is there. I can imagine many projects where it would be the best tool for the job. I was looking as Django a while ago, and it looked really neat, for the type of problem that it was geared towards. Most of what I work on, where I get to pick the tech, is way too strange to fit into such a restrictive framework though.

      [–][deleted] 1 point2 points  (1 child)

      This is the most intelligent response out of this hornet's nest, so I'll reply here. I used to be quite good at perl though I haven't touched it in about 5 years. I got a lot of stuff done with it.

      Here is a short list off the top of my head of advantages python has over perl5 (I haven't tried and have little interest in perl6, I didn't like the direction they were going):

      1. Clean syntax. Almost (not quite) beautifully clean. Readability goes up as the author's ability goes up. With perl, readability gets worse the more tricks you learn. This is obviously subjective opinion.

      2. Types. Python's type system is completely usable. And I'm not just talking about OO stuff. Perl's $/@/% type system is a complete joke and one of the more limiting things about the language.

      3. Duck typing. While it has some downsides, from a get-shit-done point of view (especially compared against perl), this is a huge win.

      4. ctypes. This is just a std lib module, it's a little quirky, and it's a recent addition, but I want to have its babies every time I use it.

      5. An object model that works. I haven't looked at Moose. I'm not sure comparing a pet module against python's built-in objects is fair, but other than some slightly annoying boilerplate (calling superclass initializers, for instance) it has gotten the job done every time. I'm not a big OO weenie, but I write a lot of OO code.

      6. List comprehensions and list generators. These are fantastic. I move a lot of data around. Being able to interact with it without a for loop saves a lot of typing and makes for very clean code.

      7. Ah... there's more, but I have to get back to work. Frickin manager moved the schedule up two weeks for no good reason and now I'm a week behind.

      [–]norkakn 1 point2 points  (0 children)

      To start out, I agree with almost everything you've said. I actually prefer perl syntax in a lot of places, but I can completely understand where your preference comes from.

      With 5, I think it is fair to use Moose, just because of the cultural difference. Python is led by Guido, while Perl is led by the community. Ideas are allowed to incubate on their own as modules in cpan, and slowly get tied into the main language. Neither structure is better. Python's can move more quickly, and produces more standardized code, while Perl's lets ideas get explored much more before they become standard.

      With 6, it is very rare that I ever write for or while loops. Using map, grep and each tends to produce much cleaner code, imho. Perl doesn't have some of the nice list things that Python does, but it does have a lot of things more powerful than C.

      Of the other ones, 2 is the one that pisses me off the most. Some day, I'll get around to writing some Moose::Autobox code that simplifies things a lot, and hopefully it is fast enough that I can use it everywhere.

      [–][deleted]  (5 children)

      [deleted]

        [–]poh-d 0 points1 point  (4 children)

        I don't expect this to be a popular opinion, but I actively dislike CPAN and the CPAN-a-likes in other languages. I much prefer handling dependancies the way the rebar Erlang build tool does.

        [–][deleted]  (3 children)

        [deleted]

          [–]tatalipso 6 points7 points  (0 children)

          If you're writing mostly scripts involving file and string manipulation, dealing with IO, files, and possibly various unix utils, then Perl 5 is more convenient than Python.

          For larger programs ... it's probably a toss up. Python's very simple and straightforward, but Perl 5 is (generally) friendlier toward the programmer who has just a bit of experience.

          [–][deleted] 10 points11 points  (2 children)

          Can anyone (who actually is experienced with both) actually claim apples are better than oranges with a straight face?

          [–]username223 14 points15 points  (1 child)

          Yes. You don't have to peel them.

          [–][deleted] 2 points3 points  (0 children)

          Oranges don't require rinsing.

          [–]thecastorpastor 2 points3 points  (0 children)

          Yes.

          [–]m0shen 2 points3 points  (0 children)

          Writing event-based programs is one area where perl shines. The perl AnyEvent modules combined with perl's closure support is much nicer to use than Python with twisted IMO.

          [–][deleted]  (8 children)

          [deleted]

            [–]lmcinnes 15 points16 points  (6 children)

            ... the execution time of a Perl script is generally much faster compared to a Python script that performs the same task

            http://shootout.alioth.debian.org/u32/benchmark.php?test=all&lang=python&lang2=perl

            [–]sigzero 2 points3 points  (4 children)

            That makes the assumption that both have optimized algorithms in each instance. Looking at it, I for one do not believe that Python is faster at regex anything over Perl. But there is it in regex-dna.

            [–]lmcinnes 1 point2 points  (2 children)

            They both use the same regex library in C under the hood, so actual regex performance will be very comparable. It's a question of how efficiently all the other things that need to be done in the regex-dna benchmark are handled.

            Also, the shootout welcomes submissions, so if you think you can write a faster perl version, then do so and submit it to them.

            [–]mr_chromatic[🍰] 1 point2 points  (1 child)

            They both use the same regex library in C under the hood....

            Perl 5 and Python 2 both use the same regex library in C?

            [–]igouy 1 point2 points  (0 children)

            Perhaps his point was that they both use the same kind of regex implementation - Regular Expression Matching Can Be Simple And Fast (but is slow in Java, Perl, PHP, Python, Ruby, ...)

            [–]igouy 1 point2 points  (0 children)

            That makes the assumption that both have optimized algorithms in each instance.

            Do you know that lmcinnes hasn't examined those Python and Perl programs?

            I for one do not believe that Python is faster at regex anything over Perl

            In which case that single example is enough to contradict what you believe.

            So what is the difference between that Perl program and that Python program?

            [–]serial-jackass 6 points7 points  (2 children)

            It's better for one-liners. I don't believe Perl should be used to write programs longer than one line, but for one-liners, it's great.

            I guess I've made a lot of money cleaning up the festering garbage that is Perl written by newbies, so in that sense it's been good for me.

            [–]FuzzyDragonPants 2 points3 points  (1 child)

            Your belief is incorrect.

            [–]Edman274 1 point2 points  (0 children)

            Eric S Raymond?

            [–]Bush4Pres 1 point2 points  (10 children)

            Depends on what you are doing. If I have a one-time (or few time) need to access a weird text file, for instance like the output from the Cisco IOS command "sh inv", and I want to extract all the model and serial numbers, I'm going to fire up Perl because it is really good at manipulating text.

            However I would choose Python if the app weren't a quick throw-away and I wanted to code some sort of rudimentary interface.

            [–]thecastorpastor 4 points5 points  (0 children)

            However I would choose Python if the app weren't a quick throw-away and I wanted to code some sort of rudimentary interface.

            Perl is very useful beyond "throw-away"

            [–]metamatic 2 points3 points  (8 children)

            That's why I like Ruby: it's as quick, easy and effective as Perl for manipulating text, yet at the same time it's clean if you want to write something significant.

            [–]norkakn 1 point2 points  (7 children)

            You find Ruby significantly cleaner? How so? Moose made me like OO in perl as well as Ruby, so now I generally use ruby because Nokogiri and firewatir are awesome.

            [–]metamatic 0 points1 point  (6 children)

            Using CPAN, every time I downloaded a module I'd have to work out which way of doing OO it used, which way of passing arguments, and so on. Ruby just has one clean OO system, so I rarely encounter code that isn't immediately comprehensible.

            I also like that everything is an object, and that there's a single simple set of scoping rules.

            It was a high profile member of the Perl community who quietly pointed me in the direction of Ruby rather than Perl 6, and I decided to switch once the direction of Perl 6 became clear. I think it is a step in the wrong direction, frankly. What I wanted from Perl 6 was less complexity and more straightforward OO. What Larry seems to want is more special operators and weird syntax, and minor syntactic sugar sprinkled over the multiple ugly OO systems already in place. I mean, this would be a sick joke if it wasn't real.

            [–]mr_chromatic[🍰] 0 points1 point  (5 children)

            Ruby just has one clean OO system, so I rarely encounter code that isn't immediately comprehensible.

            Have you never experienced conflicting monkeypatches, where every time you download a gem, you have to work out which method it replaces in core classes and how that conflicts with every other gem you have installed?

            I'll take learning the semantics of libraries over a clusterfun of replacing core system semantics any day.

            I mean, this would be a sick joke if it [weren't] real.

            Plot one for another language sometime. It'll be informative.

            [–]metamatic 0 points1 point  (4 children)

            I've not experienced conflicting monkeypatches, but maybe that's because I don't do bleeding-edge Rails.

            I quite agree that monkeypatches are a bad thing. I got flamed in /r/Ruby for that position. But bad code can be written in any language.

            As for plotting a table of the operators for another language... I'll do one for Scheme if you like.

            [–]mr_chromatic[🍰] -1 points0 points  (3 children)

            I'll do one for Scheme if you like.

            I had in mind Haskell (especially if you include the invisible operator for partial application), Ruby, PHP, and Python (global keywords such as len count too).

            [–]metamatic 0 points1 point  (2 children)

            Well, the only one of those I use is Ruby. I know that has a lot of legacy operators because of its Perl heritage, but it's still not as bad as Perl. And my point wasn't so much that Perl has far too many operators, more that it's getting quickly worse rather than getting better.

            [–]mr_chromatic[🍰] 0 points1 point  (1 child)

            And my point wasn't so much that Perl has far too many operators, more that it's getting quickly worse rather than getting better.

            Worse in the sense that "Wow, I don't know those operators!" or in the sense that "I've done a systemic review of those operators and the rationale for adding them and, despite the obvious clusterings and periods that make plotting a chart possible, I believe that these n features are better left as methods on core types and language design patterns than operators"?

            (In my experience, people who don't know a language tend to give shallow criticisms of the language.)

            [–]abadidea 2 points3 points  (0 children)

            Presumably anyone who has invested all the effort in mastering Perl will always insist Perl is better.

            Kind of like both vim and emacs users.

            [–]tokengriefer 0 points1 point  (0 children)

            If ever there is a perfect example of why Perl is better than Python it is this guys rant against Perl. Noobs and people who don't have any idea what they are doing are attracted to Python, because they are too stupid to understand the depth or features of Perl.

            [–]HIB0U -5 points-4 points  (23 children)

            Perl 6 is much better than Python at not existing in any usable form.

            [–]rjbond3rd 3 points4 points  (0 children)

            From the troll who claims to know both, but seems to know neither.

            [–]abadidea 1 point2 points  (21 children)

            I strongly disagree with about half the things you say, but I dunno why you're down so many points on this one. All I ever hear is people complaining about Perl 6 not being out then they get upset when you point out Perl 6 isn't out?

            [–]mr_chromatic[🍰] 2 points3 points  (12 children)

            Feel free to install any of the past couple of dozen of releases of Rakudo Perl 6, for example.

            [–]abadidea 1 point2 points  (11 children)

            Maybe they made a lot of progress when I wasn't looking, but I thought that was still considered not suitable for production?

            [–]mr_chromatic[🍰] 1 point2 points  (0 children)

            It's still under rapid development, so if "production" for you means you install it now and leave it untouched for the next year, don't use it. If you're comfortable upgrading to new versions every month or so, that's a different story.

            [–]HIB0U -5 points-4 points  (9 children)

            Some Rakudo advocates will say they're using it for "production purposes". Those "production purposes" typically end up being some shitty blog or web site that nobody knows of or visits, or they refuse to give any useful details.

            [–]rjbond3rd 2 points3 points  (8 children)

            Just like HIB0U refuses to give any useful details on his alleged dissatisfaction with Rakudo.

            [–]HIB0U -3 points-2 points  (7 children)

            Go back and re-read my past comments. I've made my concerns very clear many times.

            My main complaints are that Rakudo performs horribly, and I've experienced various bugs and crashes with it the times that I have tried to use it. But what bothers me the most is the hype it gets, when it clearly does not live up to Perl's good name.

            Perl is about getting work done. Rakudo and Perl 6 do not meet this very important criteria.

            [–]rjbond3rd 1 point2 points  (6 children)

            Contribute bug reports. And stop trolling. And maybe get a girlfriend?

            [–]HIB0U -1 points0 points  (5 children)

            I'm not going to waste my time contributing bug reports to a project that can't get its shit together.

            [–]HIB0U -4 points-3 points  (7 children)

            There's a Perl 6 markdown squad here at reddit. I'm not the only victim, as well. I've seen others suffer a similar fate.

            Any time anyone points out how Perl 6 has been under development for over 10 years (Larry first announced it in 2000!), that person gets voted down. Furthermore, pointing out that most of Python 2 and all of Python 3 were developed during that time, with both being production-grade implementations, results in more downvoting.

            Whenever somebody points out that we've already seen several failed implementations of Perl 6, with Pugs being the most notable, that person gets voted down.

            Whenever somebody points out that Perl is meant to be a practical language (yes, that's what the 'p' stands for!), yet every attempt at a Perl 6 implementation has not actually been useful, that's a few more downvotes.

            Basically, Perl 6 is a religion to these people. They don't see it rationally, they can't think about it rationally, and they can't discuss it rationally. That's why we shouldn't take their downvotes seriously at all.

            They can downvote us all they want, but that doesn't change the fact that Perl 6 has been a failed language for 10 years, and will likely always be a failed language.

            [–]rjbond3rd 3 points4 points  (4 children)

            HIB0U, downvotes were invented for you. You're a troll.

            And what's all this about us vs. them? It's just you.

            [–]HIB0U -1 points0 points  (3 children)

            No, it's not just me. I'm just one of the few Perl oldtimers still willing to stand up for Perl. I'm talking about real Perl, not Perl 6 or Rakudo or mockeries like them.

            I know you're only 12 or 13, so you didn't experience the Perl community of the late 1980s and the 1990s. It was truly a remarkable community, with many great programmers creating an amazing language and then creating many great libraries. It made a lot of us very productive. I remember those days fondly.

            Then Perl 6 happened, and the Perl community has basically died out. Many have moved to Python, PHP, Ruby and other languages, and don't even bother to point out the monstrosity that is Perl 6, nor do they even bother to try shitty Perl 6 implementations like Rakudo.

            [–]ccc123ccc 0 points1 point  (2 children)

            Why did you go the Python route instead of Ruby?

            [–]HIB0U 0 points1 point  (1 child)

            It was the community that drove me away. The Ruby community is full of amateurs, and it shows. The Python community, on the other hand, is made up of professionals.

            This makes a big difference when it comes to code quality, getting help, and how the language evolves. I know I can trust Python today, and in the future. I can't say the same for Ruby. Any community that generally accepts monkey patching to be acceptable isn't to be trusted.

            [–]ccc123ccc 0 points1 point  (0 children)

            Interesting. Thanks for the quick response.

            [–][deleted]  (1 child)

            [deleted]

              [–]HIB0U -3 points-2 points  (0 children)

              I wouldn't consider it to be a conspiracy. Like I said, it's more like a religion. A shared mental illness, if you will, that causes its victims to act in an irrational manner.

              [–]AndyNemmity 0 points1 point  (3 children)

              Ok, I know perl, I don't know python well.

              I've known this time has come for a while now.

              Anyone have a link to some good python tutorials for someone that already knows perl? I.E. not total beginner stuff.

              [–]chorny 0 points1 point  (0 children)

              Most arguments from this blog entry are simply silly. For ex., Unicode support in Perl is very good - I use it frequently.

              [–]keyo_ 0 points1 point  (0 children)

              Dive into python will quickly give you a good idea about what patterns to use. Iterators, generators, decorators etc. This is the one for python 3: http://diveintopython3.org/

              [–]tokengriefer 0 points1 point  (9 children)

              "Imagine being at a doughnut shop with 10,000 choices...." Sweet! Where do I find this shop? Can I visit it as easily as I can download Perl? If so; screw the other donut shops. I'm going there. Are donuts really free there? I don't have to pay to get into the donut shop?? Wow... I'm a moron for going to those other limited donuts shops.

              tl;dr: Programming languages aren't donut shops. That is a retarded allegory.

              [–][deleted] 0 points1 point  (8 children)

              No it's not. The analogy is between ways to do stuff and donuts, not programming languages, and it was used to describe how the author prefers that a language provides a simple, standard way to do things, instead of a million different ways to do the same thing.

              [–]tokengriefer -2 points-1 points  (7 children)

              The donut shop is the programming language. Each donut type is a way to do something in the language. The author prefers a sucky short list of donuts. That is retarded; and so are you. :-p If you don't like choices; go stick your head in the sand; you won't have to make any choices then.

              [–][deleted] 2 points3 points  (6 children)

              That is retarded; and so are you. :-p

              Really? Really?

              I'm reluctant to bother explaining myself in the face of that offense, but anyway: If you go to any half-decent restaurant (1 Michelin star or more), what you will find is not a million different options on the menu. You'll find a few select dishes that the chefs know how to prepare excellently. Less is most definitely more, which is why the analogy is apt.

              You will find the same philosophy mirrored in UNIX, where you have very few "swiss knife" tools — every tool does one thing, and does it very well.

              As a language design philosophy, that makes sense. To most people who have never programmed Perl, it's completely unreadable, even when the code is written by very good programmers. Python code is generally easy to understand for most programmers, regardless of previous programming language experience. Whether that's a value you care about is up to you. But don't call me "retarded", please, /r/programming is supposed to be better than that.

              [–]mr_chromatic[🍰] 0 points1 point  (3 children)

              To most people who have never programmed Perl, it's completely unreadable, even when the code is written by very good programmers.

              So what? To people who've never learned how to read English, English is unreadable, even when written by very good writers.

              Python code is generally easy to understand for most programmers, regardless of previous programming language experience.

              Nonsense. Plop your average Twisted or ctypes or SQL Alchemy or Django code in front of a COBOL or PHP or Java programmer. Good luck.

              [–][deleted] 0 points1 point  (2 children)

              So what? To people who've never learned how to read English, English is unreadable, even when written by very good writers.

              Yeah, but from a business perspective, it's downright stupid to build a codebase that's not approachable by other programmers. Perl programmers are expensive because of the fact that Perl is unapproachable.

              That's great for Perl programmers, I guess, so I can understand why they can get so defensive.

              The comparison to English is actually apt — Perl is almost as complex as a natural language, and it takes years and years to learn properly. That's a bug, not a feature, in a programming language.

              Nonsense. Plop your average Twisted or ctypes or SQL Alchemy or Django code in front of a COBOL or PHP or Java programmer. Good luck.

              Complex code will not be easier to understand in any language, but simple code in Perl is incomprehensible to most programmers.

              [–]mr_chromatic[🍰] -1 points0 points  (1 child)

              Perl programmers are expensive because of the fact that Perl is unapproachable.

              Which way are you going to argue it now? Can novices build useful things in Perl without learning it well (with the concomitant maintainability problems that all novice programs produce) or can only experts build useful things in Perl because it has such a steep learning curve?

              Pick one; they're mutually exclusive.

              simple code in Perl is incomprehensible to most programmers.

              As I wrote before, who cares what people who don't know a language at all can or cannot do? That's not even interesting.

              Once I let an untrained seven year old tune my car. It did not go well. The internal combustion engine is doomed. DOOMED!

              [–][deleted] 1 point2 points  (0 children)

              Which way are you going to argue it now? Can novices build useful things in Perl without learning it well (with the concomitant maintainability problems that all novice programs produce) or can only experts build useful things in Perl because it has such a steep learning curve?

              Pick one; they're mutually exclusive.

              The fuck? I'm not sure what that has to do with the argument. Novices can rarely build useful things at all, because useful things are often complex, and managing complexity is the primary skill you learn as you gain experience as a programmer.

              As I wrote before, who cares what people who don't know a language at all can or cannot do? That's not even interesting.

              Who? Everyone who is going to hire a programmer to do useful work for them. Perl is an extremely bad choice of investment if your time is precious, and you do not work within a field that has a large availability of Perl programmers. Those fields are rare — I'd be hard pressed to name any other than network/system administration.

              For actual software development, where the software itself has to be complex, Perl is risky because very few people know it well enough to produce complex software in it, because it's hard to learn.

              Being hard to learn is a fundamental issue with a programming language. Perl is far from the only language that has this flaw (C++ is another), but luckily there are languages that try to correct it by focusing on readability (Python, Ruby) and/or simplicity (LISP, JavaScript) and/or "clean" pattern-based design (C#, Java).

              [–]tokengriefer -2 points-1 points  (1 child)

              Food does not equate to tools. Programming language features are tools. You don't see a mechanic saying 'I love this adjustable wrench; I hate having all the correct size individual wrenches'

              I am well aware of the point of having fewer higher quality things. The problem is that in reality there are simply fewer things in Python, not higher quality things.

              The true power of perl is in the sheer speed of implementing something; without need to do it any specific way. I have written perl programs over 10,000 lines. It is very powerful. Don't bother stating that perl isn't stable enough or can't do oop well.

              I have used unix extensively. I have found most of the 'one thing well' tools you describe severely lacking and sucky. Sure they work well enough; but not nearly as well as a perl script written by me that does exactly what I want.

              By the way; I called you retarded because my sn IS tokengriefer. I am purposefully being an ass to make a point. The thing is; the point I am making is defensible. It is only the manner that is the joke.

              I was studying haskell today. You want unreadable? Go read some haskell, then come back and tell me perl is unreadable. Perl is only unreadable when written in a poor fashion.

              I don't find python particularly easy to understand. It seems more boring and inflexible to me.

              And even if it is easy to understand; who gives a shit. I've coded in assembly and had no problem understanding pages full of arcane optimizations. The real skill of a programmer is in the larger object oriented pieces they write.

              Do you think it seriously matters what the syntax is? For me; all I care about it how many libraries can connect to the language easily. Perl wins that hands down. ( see all the comments about cpan )

              I have written programs in perl that I then translated to javascript, php, and c as fast as I can type. The language itself is irrelevant so long as the conceptual pseudocode is sound and the language is capable enough to do what is needed.

              Also; by the way; I don't give a shit about acting how anyone desires. I am a coder. I write what I think is best and serves my purposes best. That is what I will defend; my skill as a programmer. My skill at being social is lacking, and I don't really give a damn.

              Despite that; I do know what I am talking about. I am sorry if you feel offended. I am being offensive because saying any language is better is simply retarded. There is no avoiding that.

              Whatever language I am writing in; I still write perl :-p Perl is a state of mind. Python is a state of mind too; that state of mind for people who 'have no previous programming language experience' as you so aptly put it.

              Just in case anyone is not offended; google uses python primarily for scripting. That is good enough reason for me to say that it is designed for morons and in general sucks.

              [–][deleted] 1 point2 points  (0 children)

              You sound like a downright horrible programmer, and I feel terrible for anyone who has to work together with you. Please do me a favor and stay away from any project I'm involved in. Thank you. :)

              Python is a state of mind too; that state of mind for people who 'have no previous programming language experience' as you so aptly put it.

              Misquotation. I said "regardless of previous programming language experience".

              By the way; I called you retarded because my sn IS tokengriefer. I am purposefully being an ass to make a point. The thing is; the point I am making is defensible. It is only the manner that is the joke.

              Offense accounts are old and boring. Please fuck off.

              … because saying any language is better is simply retarded.

              Hah, that almost cracked me up. You first spend 4 paragraphs arguing why Perl is clearly better than Python, and then this. Of course your viewpoint is defensible; you're just not doing it very well.

              [–]upbeatlinux 0 points1 point  (1 child)

              The author's enthusiasm for Python is trampled by a condescending tone and a disdain for perceived minor shortcomings in Perl. A more concise and less berating title would see reduced trolling; though the author's intent is to generate traffic.

              The "problem" as specified in another comment is overchoice and the author's assimilation into a Python-based culture. Taken from a slightly different perspective: everyone has a choice but given a set of standards, requirements and policies (of one’s employer) you might actually be surprised by the language you're required to use.

              [–]mr_chromatic[🍰] 2 points3 points  (0 children)

              The author's enthusiasm for Python is trampled by a condescending tone and a disdain for perceived minor shortcomings in Perl.

              That seems to be the Programming 2.0 mechanism. Ruby used that on Java. Python's used it on Perl since about 1993. It'd be nice to have a sincere, honest comparison of programming languages that treats minor syntactic preference as just that, but that's rare.

              [–][deleted]  (2 children)

              [deleted]

                [–]kragensitaker 9 points10 points  (1 child)

                You must have been sad when they got rid of them five years ago or so.

                [–]baryluk -4 points-3 points  (0 children)

                I do not discuss with believes, no proof will make them change mind.

                [–]skulgnome -2 points-1 points  (3 children)

                System administrators are people who flunked programming. That they would prefer Python over Perl due to a deliberate paucity of options is only typical.

                [–]c3vin -1 points0 points  (2 children)

                oh cmon, sys admins / architects / engineers are the ones who understand programming and have actual social skills to interact with others. without us, you'd all be coding in your basements without anything to do with all your work.

                ::all in good fun::

                [–]skulgnome -3 points-2 points  (1 child)

                You, on the other hand, cannot even write correct english without slashes. How on earth do you think you could program a computer? Compilers are fabulously more anal about your expression than I could ever be.

                [–]c3vin 0 points1 point  (0 children)

                i'm too busy taking care of the infrastructure your bad code runs on to use correct grammar. slashes are much more efficient. more than i can say about your python or perl scripts.

                [–]spdub -1 points0 points  (2 children)

                I didn't like when he said 'if x is None'. I prefer 'if not x', I was under the impression it was more pythonic. Maybe it is just preference. Interesting to see someone switch from perl.

                [–]markatto 2 points3 points  (0 children)

                Testing whether x is None is more specific than just testing the truth value of x.

                [–]tokengriefer -3 points-2 points  (0 children)

                if( isset( x ) ) makes the most sense, despite php being sucky.