[Python-Dev] Re: Why list.sort() uses mergesort and not timsort?

2021年6月07日 07:07:25 -0700

On Mon, 7 Jun 2021 06:49:24 -0700
Senthil Kumaran <[email protected]> wrote:
> On Sun, Jun 06, 2021 at 04:07:57PM -0700, Dan Stromberg wrote:
> > I've got a comparison of sort algorithms in both Cython and Pure Python 
> > (your
> > choice) at:
> > https://stromberg.dnsalias.org/~strombrg/sort-comparison/ 
> > ...including a version of timsort that is in Cython or Pure Python.
> > 
> 
> Interesting! timsort get's to near-linear in your benchmark.
O(n log n) always looks linear when n is small enough...
Regards
Antoine.
_______________________________________________
Python-Dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/[email protected]/message/XU6JHUNZXPLG443Z62NFPXCJKGHLLLG4/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to