3 ms·
> without sorting it... have a fixed size sorted buffer (that you sort yourself)
by rendaw 5y ago
> without sorting it... have a fixed size sorted buffer
(that you sort yourself)
- raxxorrax 5y agoThat doesn't really make sense to me at all. Don't sort it, just have it? Is the storage restriction the point?
- panda88888 5y agoYes. The goal is to find (or approximate) the median without storing all the elements. Instead, it approximates the median by finding the median of randomly selected samples from the elements.