3 ms·
> Wolfsort is primarily a proof of concept, currently it only properly supports unsigned 32 bit integers. Which makes it pretty useless outside of theoretical
by usr1106 6y ago
> Wolfsort is primarily a proof of concept, currently it only properly supports unsigned 32 bit integers.
Which makes it pretty useless outside of theoretical exercises(that is not saying that theoretical exercises would be useless). What would be a practical use case to sort integers? Well, the integers can be keys to some kind of records, but if your records remain unsorted accessing them is very expensive even if you have the sorted list of keys available.
Edit: Calculating the median is a practical case. Not sure how often that is needed in performance-critical contexts.
- joshuamorton 6y agoOf course if you want the median you do so in linear time with quickselect/k-select.
- zelly 6y agoAll radix sorts only work for integers. This isn't unique to OP's algorithm.
- deleted 6y ago[deleted]
- kd5bjo 6y agoThis is true in only the strictest sense, as computers only deal with integers: Any set of tuples/sequences can be lexicographically radix-sorted if its components can be; strings are a special case, where the components are the individual character codes. Floating point numbers are integers with the high-order bits used for the exponent. When normalized, they can be treated as integers for sorting. All radix sort requires is a recursively partitionable domain, and it performs optimally when the partitioning scheme matches the data distribution.