title: Convert array of array indices to value in multidimensional array of dynamic size
body: <p>i have an array as below :</p>
  
  <pre><code>test[
  0 =&gt; 0,
  1 =&gt; 2 ,
  2 =&gt; 0,
  3 =&gt; 2
  ]
  </code></pre>
  
  <p>the above array values are a representation on index of a larger array , so i need to covert the values to index of another array which will map the larger array as to achive below :</p>
  
  <pre><code>test2[0][2][0][2]
  </code></pre>
  
  <p>i tried :</p>
  
  <pre><code>$test3= array_flip ( $test ) 
  </code></pre>
  
  <p>works ok but is not convinient as to collisions as i dont have controll of the array , any help ?</p>