title: function to compare 2 matrices
body: <p>i got matrix and i want compare it if the elements inside it equal to another matrix in example</p>
  
  <p>i got this</p>
  
  <pre><code>$p = array();
  $p[] = array(1, 3);
  $p[] = array(1, 1);
  </code></pre>
  
  <p><strong>compare with</strong></p>
  
  <pre><code>$q = array();
  $q[] = array(1, 0);
  $q[] = array(0, 1);
  </code></pre>
  
  <p>if they equal each other , echo true ..</p>
  
  <p>i try this</p>
  
  <pre><code>for ($i = 0; $i &lt;= count($p) - 1; $i++) {
      for ($j = 0; $j &lt;= count($q) - 1; $j++) {
          if ($p[$i] == $q[$j]) {
  
              // this only for 1 elements , i want check all elements
          }
      }
  }
  </code></pre>