in reply to A hint about using map
in thread Turning foreach into map?
One of the things you always want to do with map is to use it to do a transformation on a list of strings.Huh?
Here I'm slinging just references and numbers. And using the map to do a greppy thing at the same time.@findings = map { $_->{$x} ? [ $_->{$y}, keys %$_ ] : () } @hashrefs;
|
|---|