-
What will be the output of the following PHP code?
<?php
$n = array ("16", "Interview Mania", 10, "4");
echo (array_sum ($n));
?>
-
- 16
- 10
- 30
- Interview Mania
- 4
Correct Option: C
The array_sum() function add all the values of the input array together, returning the final sum. If a string datatype is found, it’ll be ignored.