復(fù)制代碼 代碼如下:
function test($i){
$i-=4;
if($i<3){
return $i;
}else{
test($i);
}
}
echotest(30);
復(fù)制代碼 代碼如下:
function test($i){
$i-=4;
if($i<3){
return $i;
}else{
return test($i);//增加return,讓函數(shù)返回值
}
}
echotest(30);
新聞熱點(diǎn)
疑難解答