Refactors binaryRadixSort