Intuitive Sort

Basic Concept
􀂉For a given unsorted list of numbers, find the smallest number that is unmarked
􀂉Add this smallest number to a sorted list
􀂉Mark this smallest number in the unsorted list
􀂃3 algorithms are involved:
􀂉MarkSmallest
􀂉IntuitiveSort
􀂉TestIntuitiveSort (main algorithm)
Analysis of Algorithm
Space:
􀂋need an extra array of same size as input one, to store the sorted data
􀂉Operations:
􀂋For N numbers, need N2comparisons (N passes, N comparisons for each pass)

相關詞條

熱門詞條

聯絡我們