⚠️ Warning: This is a draft ⚠️

This means it might contain formatting issues, incorrect code, conceptual problems, or other severe issues.

If you want to help to improve and eventually enable this page, please fork RosettaGit's repository and open a merge request on GitHub.

Timsort is a stable sorting algorithm. It is a hybrid between Insertion sort and Merge sort so, it brings in the best of two worlds.

Time Complexity: O(nlogn) Space Complexity: O(n)

C: [[https://hg.python.org/cpython/file/default/Objects/listobject.c CPython's Timsort]]

Java: [[http://cr.openjdk.java.net/~martin/webrevs/openjdk7/timsort/raw_files/new/src/share/classes/java/util/TimSort.java OpenJDK's Timsort]]

C++: [[http://hg.savannah.gnu.org/hgweb/octave/file/0486a29d780f/liboctave/util/oct-sort.cc GNU Octave's Timsort]]