How do I create a parameter list for a function?
<p>I am creating an array of arrays in the following way:</p>

<pre><code>$final_array = array();
for($i = 0; $i &lt; count($elements); $i++) {
    for($j = 0; $j &lt; count($elements); $j++) {
        if($i!=$j)
            $final_array[] = array_intersect($elements[$i], $elements[$j]);
    }
}
</code></pre>

<p>I am trying to find out the list of elements that occur in all the arrays inside the <code>$final_array</code> variable. So I was wondering how to pass this to <code>array_intersect</code> function. Can someone tell me how to construct args using <code>$final_array[0], $final_array[1], ... $final_array[end_value]</code> for <code>array_intersect</code>? Or if there is a better approach for this, that would be great too.</p>

<p>I am looking for a way to construct the following:</p>

<p><code>array_intersect($final_array[0], $final_array[1], $final_array[2], ...)</code></p>
