- microtime: documentation ( source)
- test1: documentation ( source)
- test2: documentation ( source)
<?php
function test1()
{
$s = microtime(true);
$a = 15484;
for ($i = 0; $i < 1000000; $i++) {
$b = $a / 2;
}
return microtime(true) - $s;
}
function test2()
{
$s = microtime(true);
$a = 15484;
for ($i = 0; $i < 1000000; $i++) {
$b = $a / 2;
}
return microtime(true) - $s;
}
echo test1()."\n";
echo test2()."\n";