Libraries: Radix sort (The fastest numeric sort)

fxsaber  
Great job! The speed advantage drops by a factor of 2.5 when moving from int[] to double[].
amrali  
fxsaber #:
Great job! The speed advantage drops by a factor of 2.5 when moving from int[] to double[].
Still the fastest way you can sort floats. Faster than qsort. 
Jason Kisogloo  
This could be useful to many ;) well done ;) 
amrali  

What is this negativity?! I dont know the reason of bad stars.

If you have any suggestions or improvement please add them to the discussion.

amrali  

Update 10 April 2022

More optimized implementation with a faster speed.

fxsaber  
amrali #:

Update 10 April 2022

More optimized implementation with a faster speed.

Benchmark.


Faster:

      //--- copy back from temp to arr
    #ifdef __MQL5__
      ArraySwap(arr, temp);
    #else // #ifdef __MQL5__
      ArrayCopy(arr, temp);
    #endif // #ifdef __MQL5__ #else
amrali  
fxsaber #:

Benchmark.


Faster:

I have included these two improvements in the published code, as you suggested.

Thank you!

amrali  

Update 26 November 2022

More optimized implementation with a faster speed.

Cleaner code and minor bug fixes. 

Special thanks to fxsaber and Dominik Christian Egert