in reply to question about what to grep(?)
I think you need to provide a bit more detail about the keys of your hash. As pointed out, they cannot be arrays.
Apart from that your approach seems to make sense. The something in your grep would be some condition to select some keys from your hash.
The best approach to print depends on the values of your hash. @haystack{@wants} gives you an array of the values of the selected keys. You have not told us what these values are. They could be simple numbers or complex data structures and you would need to taylor your approach to that. Data::Dumper should always give you a printout but the question is whether it is sufficient for your purpose.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: question about what to grep(?)
by crunch_this! (Acolyte) on Apr 12, 2013 at 15:14 UTC | |
by hdb (Monsignor) on Apr 12, 2013 at 15:52 UTC | |
by crunch_this! (Acolyte) on Apr 12, 2013 at 22:35 UTC | |
by hdb (Monsignor) on Apr 13, 2013 at 08:30 UTC |