blahblah99
Platinum Member
Say I have an array of 100 elements with random numbers, and only want to keep the 10 highest numbers. What's the best way?
I don't want to sort through the whole array then pick the 10 highest, since the array can contain a million elements. Is there a variation of the sort algorithm?
TIA.
I don't want to sort through the whole array then pick the 10 highest, since the array can contain a million elements. Is there a variation of the sort algorithm?
TIA.