What will the $array array contain at the end of this script? function modifyArray (&$array) {
foreach ($array as &$value) { $value = $value + 1; } $value = $value + 2; } $array = array (1,
2, 3); modifyArray($array);

A.
2, 3, 4
B.
2, 3, 6
C.
4, 5, 6
D.
1, 2, 3
The last element of the array is still referenced, you would have to call unset($value) after the foreach to avoid it
0
0
This code is garbage.
it doesn’t work.
Result doesn’t make sense.
0
1