Ask Question
22 November, 15:15

Suppose that you have been running an unknown sorting algorithm. Out of curiosity, you once stopped the algorithm when it was part-way done and examined the partially sorted array. You discovered that the first K elements of the array were sorted into ascending order, but the remainder of the array was not ordered in any obvious manner.

Based on this, you guess that the sorting algorithm could likely be:

Shell's Sort

heapsort

quicksort

merge sort

insertion sort

+1
Answers (1)
  1. 22 November, 15:20
    0
    The sorting algorithm could likely be: insertion sort.

    Insertion Sort

    Explanation:

    There are may sort is available in programming languages, in this situation Insertion sort method is used. Here, in insertion sort, the array elements are compared with each other cells and find the smallest value from cells pushed front thus, forming a sorted ascending ordered array.

    If we stop the algorithm midway, we would get a sorted array till where the iteration is stopped and the other elements are not sorted or ordered in any way. This sort is only used to find a small number from the array, thus it is easier sorting technique than others.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “Suppose that you have been running an unknown sorting algorithm. Out of curiosity, you once stopped the algorithm when it was part-way done ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers