Let's write an inplace Heapsort in Swift

Using only extensions, learn how to implement a inplace heapsort, and order your lists in O(n log n).

Photo by chuttersnap on Unsplash

The procedures to create a inplace heapsort

Transforming the list in a heap

Sorting the heap

Computer Engineer + iOS Engineer. I am interested in Swift, Kotlin, Firebase, Data Structures, ASO & On Solving Real World Problems.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store