A
Q. What will be the output of the following PHP code?
Code:
<?php
function colour()
{
$colors = array("red", "green", "blue", "yellow");
foreach ($colors as $value)
{
echo "$value <br>";
}
}
colour();
?>
function colour()
{
$colors = array("red", "green", "blue", "yellow");
foreach ($colors as $value)
{
echo "$value <br>";
}
}
colour();
?>
- Correct Answer - Option(C)
- Views: 8
- Filed under category PHP
- Hashtags:
Discusssion
Login to discuss.