title: Using an Array to store accumulated number
body: <p>I created a for(...) cycle where I plan to go through the values of an array and use those values to accumulate them in another array, but I'm getting a notice from Apache that says <strong>Notice: Undefined offset: ...</strong>. The code I'm using is something like this:</p>
  
  <pre><code>for ($a=0;$a&lt;count($original_array);$a++){
      $accumulate_array[$a] += $original_array[$a]
  }
  </code></pre>
  
  <p>I think the notice comes from the part where I do the "+=" because it's doing something like:</p>
  
  <pre><code>$accumulate_array[$a] = $accumulate_array[$a] + $original_array[$a]
  </code></pre>
  
  <p>And it's referencing a value that still doesn't exist, I think.</p>