12 lines
276 B
Perl
12 lines
276 B
Perl
use Benchmark;
|
|
|
|
$timestamp1 = new Benchmark;
|
|
|
|
for ($loop_index = 0; $loop_index < 1_000_000; $loop_index++) {
|
|
$variable1 = 1;
|
|
}
|
|
|
|
$timestamp2 = new Benchmark;
|
|
$timedifference = timediff($timestamp2, $timestamp1);
|
|
|
|
print "The loop took", timestr($timedifference); |