Closed lain-dono closed 5 years ago
I don't believe the version here is slow (StackOverflow can often be misleading), but you're welcome to prove me wrong by submitting a pull request with an improved implementation that outperforms the current one.
https://stackoverflow.com/questions/29592546/floyd-rivest-vs-introselect-algorithm-performance says:
I also found a more correct version here: https://softwareengineering.stackexchange.com/questions/284767/kth-selection-routine-floyd-algorithm-489
However, there may also be bugs. At least with
FloydWirth_kth
, something is wrong.