In a message dated 7/28/2004 12:41:43 PM Eastern Standard Time,
[EMAIL PROTECTED] writes:
Transformation
>@input = map { $_->[0] }
> sort { lc($a->[1]) cmp lc($b->[1]) }
> map { m/\.([^.]+)$/ ? [$_, $1] : [$_, ''] } @input;
Maybe I'm missing something but since you're doing Schwartzian Transformation
already why call lc() every time?
@input = map { $_->[0] }
sort { $a->[1] cmp $b->[1] }
map { m/\.([^.]+)$/ ? [$_, lc($1)] : [$_, ''] } @input;
--
-will
http://www.wgunther.tk
(the above message is double rot13 encoded for security reasons)
Most Useful Perl Modules
-strict
-warnings
-Devel::DProf
-Benchmark
-B::Deparse
-Data::Dumper
-Clone
-Perl::Tidy
-Beautifier
-DBD::SQLite
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>