Sunday, 15 September 2013

Php while loop not working, Strange error

Php while loop not working, Strange error

Here is my php:
<?
$i = 0;
function f() {
$i++;
echo $i;
if ($i < 3) {
return true;
}
}
while(f())
?>
I was expecting output to be 123
But I get this:
Fatal error: Maximum execution time of 30 seconds exceeded in exp.php on
line 5

No comments:

Post a Comment