A
Q. What will be the output of the following PHP code ?
Code:
<?php
$arr = array("Hello", "MCQ", "Buddy");
foreach ($arr as $val)
{
if (count($arr) == 2)
print $val;
}
?>
$arr = array("Hello", "MCQ", "Buddy");
foreach ($arr as $val)
{
if (count($arr) == 2)
print $val;
}
?>
- Correct Answer - Option(D)
- Views: 10
- Filed under category PHP
- Hashtags:
Discusssion
Login to discuss.