';
// echo "Page took " . $time .' seconds.';
$time = microtime(true) - $_SERVER["REQUEST_TIME_FLOAT"];
echo "Did nothing in $time seconds
\n";
$theTime = array_sum( explode( ' ' , microtime(true) ) );
// echo $theTime.'
';
# Displays "1212018372.3366"
$testarry = range(1,99999);
echo '
COUNT TO 99999:
';
foreach( $testarry as $key => $val ) {
echo $val;
}
echo '
Do it again:
';
foreach( $testarry as $key => $val ) {
echo $val;
}
echo '
';
$theTime2 = array_sum( explode( ' ' , microtime() ) );
// echo $theTime2;
$took = $theTime2 - $theTime;
echo '
';
echo 'Elapsed time: '.$took.' seconds to count to 99,999 twice
';
echo '
';
$time = microtime(true) - $_SERVER["REQUEST_TIME_FLOAT"];
echo "Total time: $time seconds to load the page and then count to 99,000 twice
\n";
?>