Skip to content
مرتب‌سازی روان
EntityQ1714823· pop 10· linked from 67 articles

مرتب‌سازی روان

Sign in to save

In computer science, smoothsort is a comparison-based sorting algorithm. A variant of heapsort, it was invented and published by Edsger Dijkstra in 1981. Like heapsort, smoothsort is an in-place algorithm with an upper bound of operations (see big O notation). Like heapsort, smoothsort is not a stable sort. The advantage of smoothsort is that it comes closer to time if the input is already sorted to some degree, whereas heapsort averages regardless of the initial sorted state.

Key facts

Algorithm.name
Smoothsort
Algorithm.class
Sorting algorithm
Algorithm.image
|alt=An animation depicting smoothsort's operation, showing the heap being built and then disassembled,
Algorithm.caption
Smoothsort operating on an array which is mostly in order. The bars across the top show the tree structure.
Algorithm.data
Array
Algorithm.space
total, auxiliary
Algorithm.optimal
When the data is already sorted

via Wikipedia infobox

Gallery (2)