array count() problm
<pre><code>$nialiakhirpraktikum = $ntugasakhir+$ratarata; //from other process 
if ($nialiakhirpraktikum&gt;79) { $grade="A"; } 
else if ($nialiakhirpraktikum&lt;=79 AND $nialiakhirpraktikum&gt;67) { $grade="B"; } 
else if ($nialiakhirpraktikum&lt;=67 AND $nialiakhirpraktikum&gt;55) { $grade="C"; } 
else if ($nialiakhirpraktikum&lt;=55 AND $nialiakhirpraktikum&gt;44) { $grade="D"; } 
else { $grade="E"; }     
$array = array($grade); 
print_r(array_count_values($array));
</code></pre>

<p>I have some result in array like this:</p>

<pre><code>Array ( [B] =&gt; 1 ) 
Array ( [B] =&gt; 1 ) 
Array ( [C] =&gt; 1 ) 
Array ( [C] =&gt; 1 ) 
Array ( [B] =&gt; 1 ) 
Array ( [B] =&gt; 1 ) 
Array ( [B] =&gt; 1 ) 
Array ( [B] =&gt; 1 ) 
Array ( [B] =&gt; 1 ) 
Array ( [B] =&gt; 1 )
</code></pre>

<p>how to get result as following:</p>

<pre><code>score for B = 8

score for C = 2
</code></pre>
