in reply to Re: Quick Syntax check
in thread Quick Syntax check

Not only is it "faster and more concise", but it's also clear WHAT it is you're doing. In the original example, the next person reading your code thinks "OK, he busts apart the string on spaces, and then rejoins it with nothing. Why is he doing that?"

With the s/// or tr/// solutions, it's obvious: "Oh, he's deleting all the spaces."

xoxo,
Andy

%_=split/;/,".;;n;u;e;ot;t;her;c; ".   #   Andy Lester
'Perl ;@; a;a;j;m;er;y;t;p;n;d;s;o;'.  #   http://petdance.com
"hack";print map delete$_{$_},split//,q<   andy@petdance.com   >