Chad Perrin wrote:
On Thu, Dec 21, 2006 at 01:48:38AM -0600, Mumia W. wrote:
On 12/21/2006 12:42 AM, Tom Smith wrote:
Mumia W. wrote:
use strict;
use warnings;
$_ = `id $ARGV[0]`;
s/.*?groups=// && print "@{[ /\((\w+)\)/g ]}\n";
I'm not trying to be argumentative or say that this is "wrong"... But does anyone else agree with this? If so, why is this way better than the pure Perl way?

I should have put a smiley in my post :-)

Whew.  I was considering mentioning that appeared rather more obfuscated
than Tom's example.  Clever, though.

Yeah, the smiley may have clarified the intentions a little... My first reaction when I saw the code was one of great surprise--I just wasn't seeing how that would be easier to understand or the "cleaner" way to achieve what I wanted. But now I get it. :-)

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to