>>>>> "CD" == Chris Devers <[email protected]> writes:

  CD> On Tue, May 31, 2011 at 4:44 PM, Uri Guttman <[email protected]> wrote:
  >>                assign => sub { my $x = 'abc' ; $x = "qwerty/$x" },
  >>                substr => sub { my $x = 'abc' ; substr( $x, 0, 0, 
'qwerty/') },

  CD> The substr version doesn't look very readable or maintainable.

  CD> You're teaching *beginners* to do things this way?

well, not teaching it. i offered an alternative and faster way to
prepend a string. some on the beginner's list are very capable of using
substr in all its forms. the OP actually looked up the docs and found
lvalue substr but i replied it shouldn't be used as 4 arg substr can do
the same thing and is much faster.

uri

-- 
Uri Guttman  ------  [email protected]  --------  http://www.sysarch.com --
-----  Perl Code Review , Architecture, Development, Training, Support ------
---------  Gourmet Hot Cocoa Mix  ----  http://bestfriendscocoa.com ---------

_______________________________________________
Boston-pm mailing list
[email protected]
http://mail.pm.org/mailman/listinfo/boston-pm

Reply via email to