$countries = array( 'USA' => 'English', 'Spain' => 'Spanish',
'France' => 'French', 'Argentina' => 'Spanish');
$languages = array_values($countries);
$language_count = array();
foreach($languages as $language)
if(!isset($language_count[$language]))
$language_count[$language] = 1;
else
$language_count[$language]++;
?>
Language Number
of
Countries
foreach($language_count as $language => $number)
print "$language $number \n";
?>