title: PHP - obtaining sub-array in a single expression
body: <p>Is there a way to get, in a single expression, a sub-array from an array, giving specific keys from the original array?</p>
  
  <p>By example:</p>
  
  <pre><code>$a = array('a' =&gt; 1, 'b' =&gt; 2, 'c' = 4, 'd' =&gt; 'clorch')
  $b = doesthisfunctionexist($a, 'a', 'c')
  //$b containing array('a' =&gt; 1, 'c' =&gt; 4)
  </code></pre>
  
  <p>I know I can code that function, but I'm asking if such a similar native function exists.</p>