-
What will be the output of the following PHP code?
<?php
$First = array_fill(1, 4, "Interview");
$Second = array_fill(5, 1, "Mania");
$Third = array_merge($First, $Second);
print_r($Third);
echo "\n";
print_r($Second);
?>
-
-
Array
(
[0] => Interview
[1] => Interview
[2] => Interview
[3] => Interview
[4] => Mania
) -
Array
(
[5] => Mania
) -
Array
(
[5] => Mania
)
Array
(
[0] => Interview
[1] => Interview
[2] => Interview
[3] => Interview
[4] => Mania
) -
Array
(
[0] => Interview
[1] => Interview
[2] => Interview
[3] => Interview
[4] => Mania
)
Array
(
[5] => Mania
) - None of these
-
Correct Option: D
Usage of array_fill() and array_merge() functions.