Home  >  Article  >  Backend Development  >  Learn the examples of parameter reference return in dynamic web technology PHP_PHP tutorial

Learn the examples of parameter reference return in dynamic web technology PHP_PHP tutorial

WBOY
WBOYOriginal
2016-07-13 17:30:14921browse

$a = 1;
function b(&$c)
{
    $c++;
    return $c;
}
$d=b($a);
$d++;
echo($a);
?>

$a = 1;
function &b(&$c)
{
    $c++;
    return $c;
}
$d=&b($a);
$d++;
echo($a);
?>

www.bkjia.comtruehttp://www.bkjia.com/PHPjc/509192.htmlTechArticle?php $a = 1; function b($c) { $c++; return $c; } $d=b($a); $d++; echo($a); ? ?php $a = 1; function b($c) { $c++; return $c; } $d=b($a); $d++; echo($a); ?...
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn