Help for this page

Select Code to Download


  1. or download this
        use List::Util qw/sum/;
        $header{"Number of Drills"} = sum
                map $_->count,
                map { values %{ $_->tool } } @drill_arr;
    
  2. or download this
        timethese(-6, {
            'sum' => sub {
    ...
                } };
            },
        });
    
  3. or download this
    Benchmark: running sub, sum, each for at least 6 CPU seconds...
           sub:  7 wallclock secs ( 6.00 usr +  0.00 sys =  6.00 CPU) @ 15
    +883.17/s (n=95299)
           sum:  6 wallclock secs ( 6.02 usr +  0.00 sys =  6.02 CPU) @ 40
    +993.85/s (n=246783)