[thelist] recursive PHP functions

Jay Blanchard jay.blanchard at niicommunications.com
Mon Sep 16 10:32:07 CDT 2002

function recursive ($n)
    if ($n > 10) return $n;
	recursive ($n);
echo "The result:".rec1(1)."<br>";

There is no recursive() function in PHP, this is a self-defined function. If
$n is greater than 10 then the number will be incremented by one and then
returned. Is this what you want?



More information about the thelist mailing list