- or download this
$re = qr/$regex/;
$_ =~ $re;
- or download this
use Benchmark;
...
b => sub { $b->(qw(this is a test bob and jobe)) },
c => sub { grep $pat, qw(this is a test bob and jobe) }
});
- or download this
Benchmark: timing 100000 iterations of a, b, c...
a: 7 wallclock secs ( 5.92 usr + 0.00 sys = 5.92 CPU) @ 16
+891.89/s (
...
n=100000)
c: 0 wallclock secs ( 0.62 usr + 0.00 sys = 0.62 CPU) @ 16
+1290.32/s
(n=100000)