Is it me or can we just not win.

I work for a big company in London, and I was chatting with another development team
who are currently using perl, but moving to Java & Javascript.

Their reason!!! Perl is just too flexible!!!


Anyone else out there had this problem???

Replies are listed 'Best First'.
Re: Just Cant Win
by abstracts (Hermit) on Aug 11, 2001 at 00:06 UTC
    Here is a story I read long time ago, but it applies to this thread.

    Perl "Too Good"

    This is a true story. Names have not been changed.

    UCLA's Computer Science Undergraduate Association regularly hosts its programming competition. Contestants are given six complex problems and have three hours to write programs to solve as many of the problems as possible. In 1997, the rules stated that any programming language could be used so long as you solved the problem, so then-undergraduate Keith Chiem entered and used Perl.

    Keith did not merely win, he conquered. He solved five of the six problems in the three hours allotted. The second-place two-person team solved only three problems. They, needless to say, were not using Perl.

    But if you're a UCLA undergraduate contemplating entering the contest and using Perl, don't bother. After Keith's conquest, Perl was banned from the contest.

    You've got to admire a language that is banned because it makes problems too easy to solve.

    These days, Keith is a sysadmin at Yahoo! Inc., and is wondering what to do with the copy of Visual C++ that was his prize.

     

    Aziz,,,

Re: Just Cant Win
by davorg (Chancellor) on Aug 10, 2001 at 20:28 UTC
Re: Just Cant Win
by jima (Vicar) on Aug 10, 2001 at 21:02 UTC
    In the Perl discussions on The WELL, someone made this very point about using Perl as a system admin language. They compared Perl with C, and said that, once they learned C, they felt that they knew the whole language. With Perl, there's always more stuff to learn, and you never get the feeling that you know it all, and are constantly having to figure out the new tricks in other people's code. The argument ends thusly:
    Don't get me wrong, I *like* Perl, but my ideal system language is finite.
      The other day one of the other developers here was looking at some of my code where I'd done something like:
      if (-d $foo) { ... } elsif (-s _) { ... }
      He had never seen the _ file-test optimization and leaped to the conclusion that it was a syntax error. My response to him was not very kind--I literally told him to RTFM--but I can sort of sympathize with the position he was in. For whatever reason he was unaware of that particular feature, and it may not be immediately obvious where to find out about it. In hindsight, sure, go to the file-test-operator documentation, but it could just as easily have been some obscure variable/bareword syntax, or a call to a function named '_'. And for that matter, if you didn't know the right perldoc command to show the file-test documentation, it'd probably take a few tries to find it. I've been using perl since version 3.something, but there are lots of times I get tired of having to keep track of all the syntax idiosyncracies.
Re: Just Cant Win
by lemming (Priest) on Aug 10, 2001 at 22:55 UTC

    That's a coincidence. Ovid and I were talking with a developer who didn't like Perl for similar reasons. For him, it was a maintainability issue. Since Perl gives you so many ways of doing the same thing, how could someone come in and understand the previous programmer's work? Though, he seemed to be biased in any case.

    I may be being naive, but can't people use a style guide and actually trust their people? I'm also thinking no one does code review anymore. It's sad when one has to use a less flexible language because you don't want to give your programmers too much power. Do we really want to dumb down to the lowest denominator?

    Note that I'm ranting against the people, not the other languages.

Re: Just Cant Win
by agent00013 (Pilgrim) on Aug 11, 2001 at 00:03 UTC
    Another of the Java debates has begun here, it seems. Perl is a great language. I agree to that. It's quite easy to script things for use in it. It works great for web stuff and CGI. but...

    Java has its own benefits. "Write once, run anywhere" isn't always true, but it is in a lot of cases. Developing enterprise scale applications for customers which require a GUI interface (yeah, and they want it pretty, too... can you imagine;) is also easier with Java (assuming you're using a good production environment and not trying to develop code using Notepad)

    Understanding code written by a lazy Perl programmer is a lot harder then reading lazy Java code. Sometimes its nice to be lazy, but when somebody comes along a year or two later trying to update a 2000 line script with 15 subs, no use strict; or -w, it's takes weeks to rewrite the thing, be properly laid out, and random globals not floating between functions. (Three weeks, actually.)

    Personally, I think anyone can win despite what language they're developing in. Just make sure you're using the right language for the right job.

    Love is random; fear is inevitable. -- Orson Scott Card
    PerlMonks is good for Perl, but JavaJunkies is good for Java
      I'll second that motion... It's the quality of the programmer, not the language... I would be willing to bet, that if you took perl away from most monks (AUGGG!!!! BLASPHEMY) that they would still be able to complete almost any task requested of them...

      And that bit about the 2000 line script? Yea, I know all about that....

      thanks!
      E-Bitch