OM The Eternity OM The Eternity - 19 days ago 6
PHP Question

if $a and $b are bothe arrays the what would be the result of $a+$b?


Possible Duplicate:

+ operator for array in PHP?




If
$a
and
$b
are both arrays, what is the result of
$a + $b
?

Answer

http://www.php.net/manual/en/language.operators.array.php

Union of $a and $b.

The + operator appends elements of remaining keys from the right handed array to the left handed, whereas duplicated keys are NOT overwritten.