Benchmark timethis : Benchmark « System Functions « Perl






Benchmark timethis

     
#!/usr/bin/perl
use warnings;
use strict;
use Benchmark;
my $howmany = 10000;
my $what = q/my $j=1; for (1..100) {$j*=$_}/;
timethis($howmany, $what);

   
    
    
    
    
  








Related examples in the same category

1.use Benchmark to time a loop