1.

What will be the output of the following PHP code ?
<?php
$p=7;
function calc()
{
echo $GLOBALS['p'];
$GLOBALS['p']++;
}
calc();
calc();
calc();
?>

A. 7
B. 789
C. 78
D. 89
E. None of these
Answer» C. 78


Discussion

No Comment Found

Related MCQs