I'd go the array route.
1. Array with your dataset
2. Sort Array based on amount
3. Loop through array, copy the current entry into another Array. Compare the "loopindex" amount with the "loopindex+1" amount. If the comparison is true, repeat the loop, otherwise stop the loop.
4. You now have an array that contains all fruits that tied for the highest amount (one or more)
5. You can output a random entry from that array like Array.At(floor(random(0,Array.length+1)))