The usage of solving a php array shows a code written by someone else, similar to this:
$a = array();$a['key'] = $a['key'] + 1;var_dump($a);
As you can see, 1 in the code changes to the value of array ..
This .. I have never used it like this ..
Reply to discussion (solution)
Accumulate, similar to a + = 1;
Is an array...
Equivalent to $ a ['key'] = null + 1;
Equivalent to $ a ['key'] = null + 1;
Don't understand ..
Equivalent to $ a ['key'] = null + 1;
Don't understand ..
Not understand
Equivalent to $ a ['key'] = null + 1; positive solution
$ A = array ();
$ A ['key'] = $ a ['key'] + 1; // at this time, $ a ['key'] does not exist, use isset ($ a ['key']) to return false, so $ a ['key'] = null
$ A ['key'] + 1 is equivalent to null + 1 because php will automatically convert null to 0 for arithmetic operations, so it is 0 + 1, last $ a ['key'] = 1
Var_dump ($ );
It is best not to write like this. php is a weak-type statement. if you want to improve the execution efficiency, you 'd better declare the type in advance instead of letting the system identify it.
Equivalent to $ a ['key'] = null + 1;
Don't understand ..
Not understand
Oh .. I understand. I understood it wrong.