Edit previous code didn't work.
// $seenDuplicate[ Percentage ][] = indexes which have this percentage.
foreach(team_array as $ind => $team){
$trackPercentages[$team[4]][] = $ind;
}
// then you can count the number of each array in $trackPercentages
Reply to first comment: it's returning 3 because it contains all percentages regardless of duplication. The first is 1.000, second is .5000 and 3rd is .0000
foreach($trackPercentages as $perc => $list){
$echo "Teams with " . $perc . "% wins.<br>";
foreach($list as $team){
echo $team."<br>";
}
echo "<br>";
}
if you only want to show duplicates, then right after first foreach loop, check:
if(count($list)>1)
And I believe ksort can be used to sort an array based on index.