Selection Sort: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
(Created page with "=Internal= * Sorting Algorithms =Overview= Selection sort scans the input array from left to right, determining the minimum elemen...")
 
Line 7: Line 7:
Selection sort scans the input array from left to right, determining the minimum elements in the subarray spanning from the current position to the end of the input array and then swap the current element with the minimum.  
Selection sort scans the input array from left to right, determining the minimum elements in the subarray spanning from the current position to the end of the input array and then swap the current element with the minimum.  


It is an in-place sorting mechanism
It is an [[Sorting_Algorithms#In-place|in-place]] sorting mechanism with a n<sup>2</sup> growth order

Revision as of 21:24, 6 August 2018

Internal

Overview

Selection sort scans the input array from left to right, determining the minimum elements in the subarray spanning from the current position to the end of the input array and then swap the current element with the minimum.

It is an in-place sorting mechanism with a n2 growth order