or the map grep combo:@modified_list = map { $_ =~ /good stuff/ : #do stuff here ? () } @array;
-enlil@modified_list = map { #do stuff here } grep { /good_stuff/ } @array
In reply to Re: "foreach" is to "next" as "map" is to ???
by Enlil
in thread "foreach" is to "next" as "map" is to ???
by McMahon
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |