in reply to Re^7: Thread on Joel on software forum : "I hate Perl programmers."
in thread Thread on Joel on software forum : "I hate Perl programmers."

Seriously? $_ is always harder to understand than a well-named variable.
  • Comment on Re^8: Thread on Joel on software forum : "I hate Perl programmers."

Replies are listed 'Best First'.
Re^9: Thread on Joel on software forum : "I hate Perl programmers."
by BUU (Prior) on Jun 17, 2005 at 04:17 UTC
    Um. Yes?
    for( @birds ) { next unless /bar/; s/puffin/poppin/; print; }
    Versus
    for $bird (@birds) { next unless $bird =~ /bar/; $bird =~ s/puffin/poppin/; print $bird; }
    Maybe it's me or my choice of code, but I don't really see the second one as being much harder to understand.
      No big deal -- we just diagree. I think the second is easier to read. Incidentally, you didn't explicitly use $_ here, just default function args. I find it more jarring when the $_ is explicit.