title: Count of duplicate values in array php
body: <p>I have this Array:</p>
  
  <pre><code>Array ( [0] =&gt; Array ( [Num] =&gt; 2 ) [1] =&gt; Array ( [Num] =&gt; 3 ) [2] =&gt; Array ( [Num] =&gt; 13 ) [3] =&gt; Array ( [Num] =&gt; 2 ) [4] =&gt; Array ( [Num] =&gt; 3 ) [5] =&gt; Array ( [Num] =&gt; 3 ) [6] =&gt; Array ( [Num] =&gt; 1 ) [7] =&gt; Array ( [Num] =&gt; 44 ) ) 
  </code></pre>
  
  <p>And i want to get the number of duplicate values for example that array have 5 values duplicated.
  simple way for this problem??help me!</p>
  
  <p>php code:</p>
  
  <pre><code>$count = 0;
  $temp = array();
  for($i=0;$i&lt;=sizeof($Num);$i++){
      for($j=$i+1;$j&lt;=sizeof($Num);$j++){
          if($Num[$i]==$Num[$j]){
              $count++;
              $temp[]=$Num[$j];
          }
      }
  }
  var_dump($temp);
  echo $count;
  </code></pre>