Answer to Question #52160 in Other Programming & Computer Science for irebami
Question #52160
Sorting algorithms are often classified by the following, except?
Computational complexity
Computational complexity of swaps
Recursion
None of the options is correct
Computational complexity
Computational complexity of swaps
Recursion
None of the options is correct
Expert's answer
Solution:
Sortingalgorithms are often classified by:
- Computational complexity (worst, average and bestbehavior) of element comparisons in terms of the size of the list (n). For
typical serial sorting algorithms good behavio
r- Computational complexity ofswaps (for inplace algorithms).
- Memoryusage (and use of other computer resources). In particular, some sorting
algorithms are in place.
- Recursion. Some algorithms are eitherrecursive or non-recursive, while others may be both (e.g., “Merge Sort”).
- Stability:stable sorting algorithms maintain the relative order of records with equal
keys (i.e., values).
- Whetheror not they are a comparison sort. A comparison sort examines the data only by
comparing two elements with a comparison operator.
- Generalmethod: insertion, exchange, selection, merging, etc. Exchange sorts include
bubble sort and quicksort. Selection sorts include shaker sort and heapsort.
Also whether the algorithm is serial or parallel. The remainder of this
discussion almost exclusively concentrates upon serial algorithms and assumes
serial operation.
- Adaptability:Whether or not the presortedness of the input affects the running time.
Algorithms that take this into account are known to be adaptive.
Answer:None of the options is correct
Sortingalgorithms are often classified by:
- Computational complexity (worst, average and bestbehavior) of element comparisons in terms of the size of the list (n). For
typical serial sorting algorithms good behavio
r- Computational complexity ofswaps (for inplace algorithms).
- Memoryusage (and use of other computer resources). In particular, some sorting
algorithms are in place.
- Recursion. Some algorithms are eitherrecursive or non-recursive, while others may be both (e.g., “Merge Sort”).
- Stability:stable sorting algorithms maintain the relative order of records with equal
keys (i.e., values).
- Whetheror not they are a comparison sort. A comparison sort examines the data only by
comparing two elements with a comparison operator.
- Generalmethod: insertion, exchange, selection, merging, etc. Exchange sorts include
bubble sort and quicksort. Selection sorts include shaker sort and heapsort.
Also whether the algorithm is serial or parallel. The remainder of this
discussion almost exclusively concentrates upon serial algorithms and assumes
serial operation.
- Adaptability:Whether or not the presortedness of the input affects the running time.
Algorithms that take this into account are known to be adaptive.
Answer:None of the options is correct
Comments
Leave a comment