in reply to Am I developing poor style?
On the other hand, if this is something you might want to do later, there's no reason not to turn it into a function itself. Regardless, here's the damage that Dominus may cheer and merlyn will jeer:
Yuck. :)$header{'Number of Drills'} = (map { $total += $_->{count} foreach (values %{ $_->{tool} }); $total } @drill_arr)[-1];
Update: I spent too long getting this to work and forgot about do. Don't hate me because I wrote perverse code. Just live and learn.
|
|---|