Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked

Re: "Baby" Perl versus "Bad" Perl

by dragonchild (Archbishop)
on Dec 03, 2005 at 23:09 UTC ( #513868=note: print w/replies, xml ) Need Help??

in reply to "Baby" Perl versus "Bad" Perl

Let's say you have two children. One is 8 and the other is 3. They both exhibit the same kinds of behavior - drawing on walls, throwing tantrums, willful disobedience, and the like. Which is bad and which is the baby?

On one level, both are behaving badly and, as such, shouldn't be taken to a restaurant. However, that kind of behavior is expected for the 3yr old and not expected for the 8yr old. Why? Because the 8yr old is expected to have matured and (mostly) grown out of that phase. And that is the difference between "baby Perl" and "bad Perl." If you are a newbie, then your Perl is baby Perl. If you are a supposed expert (as all authors are supposed to be), then your Perl is bad Perl. Neither would be allowed on my boxes in a million years, but one is expected behavior and the other is not.

My criteria for good software:
  1. Does it work?
  2. Can someone else come in, make a change, and be reasonably certain no bugs were introduced?

Replies are listed 'Best First'.
Re^2: "Baby" Perl versus "Bad" Perl
by sauoq (Abbot) on Dec 04, 2005 at 23:09 UTC

    I don't think your criteria is very good. You seem to be saying that whether Perl code is "baby" or "bad" depends on the experience of the programmer. I don't think that's true. "Baby Perl" can be distinguished from "Bad Perl" without asking the developer how long he has been coding.

    I think that there are things that mark code as bad. Incorrect code is bad. Insecure code is bad. Code with significant performance problems is bad. Code that is difficult to maintain is bad.

    But there can be "baby" Perl (or any programming language) that exhibits none of those problems. It might be simplistic and lacking in idiomatic expression. It probably doesn't use any "advanced" language features. But none of that makes it bad.

    BTW, I'd much rather deal with a junior programmer who is writing "baby" Perl (good or bad) than any programmer writing bad but "advanced" code. ;-)

    "My two cents aren't worth a dime.";

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://513868]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (5)
As of 2018-06-18 04:41 GMT
Find Nodes?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?

    Results (107 votes). Check out past polls.