title: Combine array and add key for each array
body: <p>I just can't find the right question for this</p>
  
  <p>pretty much merging array From this</p>
  
  <pre><code>$arr1 = ["temp1", "temp2", "temp3"];
  $arr2 = [5, 7, 2];
  </code></pre>
  
  <p>to this</p>
  
  <pre><code>$combined = [["name" =&gt; "temp1", "number" =&gt; 5], ["name" =&gt; "temp2", "number" =&gt; 7], ["name" =&gt; "temp3", "number" =&gt; 2]];
  </code></pre>
  
  <p>any idea to do it in most efficient way other than foreach?</p>