Voting

Please answer this simple SPAM challenge: max(zero, one)?
(Example: nine)

The Note You're Voting On

bytepirate
8 years ago
in additon to blakes comment. try this:

<?php
$strlen
=60000;
$bstring=str_repeat("X",$strlen);
$astring=$bstring;
$starttime=microtime(true);
for(
$i=0;$i<=$strlen;$i++){
  if(
$i==strlen($astring))
     echo
"End of String<br>";
}
echo (
microtime(true)-$starttime)." seconds expired";
?>

and now change '$astring=$bstring;' to '$astring=&$bstring;'
on my system its 200 times slower with the reference.
increase $strlen and it gets even worse ;-)

(PHP 5.25 on UNIX)

<< Back to user notes page

To Top