Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl -w
    use Benchmark;
    use strict;
    ...
    
    timethese(500, { 'each' => \&e,
             'keys' => \&k });
    
  2. or download this
    Benchmark: timing 500 iterations of each, keys...
        each:  4 wallclock secs ( 3.77 usr +  0.01 sys =  3.78 CPU)
        keys:  5 wallclock secs ( 4.85 usr +  0.00 sys =  4.85 CPU)